Title: Uncaught TypeError when creating new post
Last modified: December 19, 2025

---

# Uncaught TypeError when creating new post

 *  [Pat Harvey](https://wordpress.org/support/users/patchh/)
 * (@patchh)
 * [5 months, 3 weeks ago](https://wordpress.org/support/topic/uncaught-typeerror-when-creating-new-post/)
 * On my site, when I go to create a new wordpress post I got this error
 * `An error of type E_ERROR was caused in line 762 of the file /home/customer/www/
   DOMAIN.org/public_html/wp-content/plugins/woocommerce-pdf-invoices-packing-slips/
   includes/Frontend.php. Error message: Uncaught TypeError: WPO\IPS\Frontend::edi_peppol_display_classic_checkout_fields():
   Argument #1 ($fields) must be of type array, bool given,`
 * In order to be able to get the site working again, I have had to amend this line
   as below. is that a safe change?
 * Many thanks
 * Pat
 *     ```wp-block-code
       public function edi_peppol_display_classic_checkout_fields( $fields ) {    if ( ! is_array( $fields ) ) {        return $fields;    }
       ```
   

Viewing 1 replies (of 1 total)

 *  Plugin Contributor [alexmigf](https://wordpress.org/support/users/alexmigf/)
 * (@alexmigf)
 * [5 months, 3 weeks ago](https://wordpress.org/support/topic/uncaught-typeerror-when-creating-new-post/#post-18762330)
 * Hi [@patchh](https://wordpress.org/support/users/patchh/)
 * Could you please replace your plugin with [this version](https://github.com/wpovernight/woocommerce-pdf-invoices-packing-slips/releases/download/v5.3.0-beta.1/woocommerce-pdf-invoices-packing-slips.5.3.0-beta.1.zip)?
 * Let us know if that fixes the issue.

Viewing 1 replies (of 1 total)

You must be [logged in](https://login.wordpress.org/?redirect_to=https%3A%2F%2Fwordpress.org%2Fsupport%2Ftopic%2Funcaught-typeerror-when-creating-new-post%2F%3Foutput_format%3Dmd&locale=en_US)
to reply to this topic.

 * ![](https://ps.w.org/woocommerce-pdf-invoices-packing-slips/assets/icon-256x256.
   png?rev=2189942)
 * [PDF Invoices & Packing Slips for WooCommerce](https://wordpress.org/plugins/woocommerce-pdf-invoices-packing-slips/)
 * [Frequently Asked Questions](https://wordpress.org/plugins/woocommerce-pdf-invoices-packing-slips/#faq)
 * [Support Threads](https://wordpress.org/support/plugin/woocommerce-pdf-invoices-packing-slips/)
 * [Active Topics](https://wordpress.org/support/plugin/woocommerce-pdf-invoices-packing-slips/active/)
 * [Unresolved Topics](https://wordpress.org/support/plugin/woocommerce-pdf-invoices-packing-slips/unresolved/)
 * [Reviews](https://wordpress.org/support/plugin/woocommerce-pdf-invoices-packing-slips/reviews/)

 * 1 reply
 * 2 participants
 * Last reply from: [alexmigf](https://wordpress.org/support/users/alexmigf/)
 * Last activity: [5 months, 3 weeks ago](https://wordpress.org/support/topic/uncaught-typeerror-when-creating-new-post/#post-18762330)
 * Status: not resolved