[wp-trac] [WordPress Trac] #54973: Failed wp_insert_category() when IMPORT_DEBUG is set to true produces a fatal error.

WordPress Trac noreply at wordpress.org
Sat Jan 29 08:15:11 UTC 2022


#54973: Failed wp_insert_category() when IMPORT_DEBUG is set to true produces a
fatal error.
-------------------------------------+---------------------
 Reporter:  enshrined                |       Owner:  (none)
     Type:  defect (bug)             |      Status:  new
 Priority:  normal                   |   Milestone:  6.0
Component:  Import                   |     Version:
 Severity:  normal                   |  Resolution:
 Keywords:  has-patch needs-refresh  |     Focuses:
-------------------------------------+---------------------
Changes (by mukesh27):

 * keywords:  has-patch => has-patch needs-refresh


Comment:

 Hi there! thanks for the ticket and patch.

 Can you please add `is_wp_error` for below all occurrences so we don't get
 a similar error in any other code base?

 https://github.com/WordPress/wordpress-
 importer/blob/99462ec2d3390bc0de3bc5ffbe817f2160e5ef54/src/class-wp-
 import.php#L374-L376

 https://github.com/WordPress/wordpress-
 importer/blob/99462ec2d3390bc0de3bc5ffbe817f2160e5ef54/src/class-wp-
 import.php#L484-L486

 https://github.com/WordPress/wordpress-
 importer/blob/99462ec2d3390bc0de3bc5ffbe817f2160e5ef54/src/class-wp-
 import.php#L545-L547

 https://github.com/WordPress/wordpress-
 importer/blob/99462ec2d3390bc0de3bc5ffbe817f2160e5ef54/src/class-wp-
 import.php#L757-L759

 https://github.com/WordPress/wordpress-
 importer/blob/99462ec2d3390bc0de3bc5ffbe817f2160e5ef54/src/class-wp-
 import.php#L793-L795

-- 
Ticket URL: <https://core.trac.wordpress.org/ticket/54973#comment:3>
WordPress Trac <https://core.trac.wordpress.org/>
WordPress publishing platform


More information about the wp-trac mailing list