{"id":12233821,"date":"2019-12-13T06:10:05","date_gmt":"2019-12-13T06:10:05","guid":{"rendered":"https:\/\/wordpress.org\/support\/?post_type=topic&#038;p=12233821"},"modified":"2019-12-13T07:29:45","modified_gmt":"2019-12-13T07:29:45","slug":"request-for-code-corrections","status":"publish","type":"topic","link":"https:\/\/wordpress.org\/support\/topic\/request-for-code-corrections\/","title":{"rendered":"Request for code corrections"},"content":{"rendered":"<p>Greetings,<\/p>\n<p>You&#8217;ve got the makings of a nice Plugin. Updating some of the code would make it much better. Here are some examples.<\/p>\n<p>Using WP 5.3 and plugin v2.0.6 on Apache and PHP v7.2<\/p>\n<p>Admin -&gt; Xtra Settings &#8211; follow errors on page load:<br \/>\nWarning\tcount(): Parameter must be an array or an object that implements Countable<\/p>\n<p>    wp-content\/plugins\/xtra-settings\/admin-setting.php:573<br \/>\n    xtra_get_image_quality()<\/p>\n<p>    wp-content\/plugins\/xtra-settings\/admin-setting.php:553<br \/>\n    xtra_get_images()<\/p>\n<p>    wp-content\/plugins\/xtra-settings\/admin-setting.php:1534<br \/>\n    xtra_html_page()<\/p>\n<p>Warning (Suppressed)\texif_read_data(CellPhones.jpg): Incorrect APP1 Exif Identifier Code\t1<br \/>\nwp-content\/plugins\/xtra-settings\/admin-setting.php:572<\/p>\n<p>On the front-end:<br \/>\nNotice\tWP_Admin_Bar::add_node was called incorrectly. The menu ID should not be empty. Please see Debugging in WordPress for more information. (This message was added in version 3.3.0.)<\/p>\n<p>17 times\twp-includes\/functions.php:4903\tPlugin: xtra-settings<br \/>\n&#8211; I know this was reported in a previous support thread where you stated it wasn&#8217;t related to your plugin&#8211;but it appears that somehow it is.<\/p>\n<p>Deprecated\tFunction create_function() is deprecated\t1<br \/>\n    wp-content\/plugins\/xtra-settings\/xtra.php:2227<br \/>\n    wp-settings.php<br \/>\n    wp-settings.php:360<\/p>\n<p>If the plugin is disabled, all the above goes away.<\/p>\n<p>To see the above I used the Plugin: Query Monitor (https:\/\/wordpress.org\/plugins\/query-monitor\/)<\/p>\n<p>Cheers,<\/p>\n","protected":false},"template":"","class_list":["post-12233821","topic","type-topic","status-publish","hentry"],"jetpack_sharing_enabled":true,"_links":{"self":[{"href":"https:\/\/wordpress.org\/support\/wp-json\/wp\/v2\/topic\/12233821","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/wordpress.org\/support\/wp-json\/wp\/v2\/topic"}],"about":[{"href":"https:\/\/wordpress.org\/support\/wp-json\/wp\/v2\/types\/topic"}],"version-history":[{"count":1,"href":"https:\/\/wordpress.org\/support\/wp-json\/wp\/v2\/topic\/12233821\/revisions"}],"predecessor-version":[{"id":12234251,"href":"https:\/\/wordpress.org\/support\/wp-json\/wp\/v2\/topic\/12233821\/revisions\/12234251"}],"wp:attachment":[{"href":"https:\/\/wordpress.org\/support\/wp-json\/wp\/v2\/media?parent=12233821"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}