{"id":13734810,"date":"2020-12-02T11:32:46","date_gmt":"2020-12-02T11:32:46","guid":{"rendered":"https:\/\/wordpress.org\/support\/topic\/error-method-does-not-exist\/"},"modified":"2020-12-02T11:32:46","modified_gmt":"2020-12-02T11:32:46","slug":"error-method-does-not-exist","status":"publish","type":"topic","link":"https:\/\/wordpress.org\/support\/topic\/error-method-does-not-exist\/","title":{"rendered":"Error: Method does not exist"},"content":{"rendered":"<p>I have a scheduling post plugin for WordPress. It works pretty well. but today I see an error on Query Monitoring plugin.<\/p>\n<pre><code>ScheduleMenu-&gt;load_pre_schedule_queue()\nError: Method ScheduleMenu::load_pre_schedule_queue() does not exist<\/code><\/pre>\n<p>I do not know why WordPress could not find the method! but everything works fine!<\/p>\n<p>admin-menu.php:<\/p>\n<pre><code>require_once SCHEDULE_PLUGIN_DIR . &#039;libs\/admin-page-framework\/admin-page-framework.php&#039;;\nrequire_once SCHEDULE_PLUGIN_DIR . &#039;admin\/settings.php&#039;;\nrequire_once SCHEDULE_PLUGIN_DIR . &#039;admin\/queue.php&#039;;\nclass ScheduleMenu extends LazyCoala_AdminPageFramework\n{\n    public function setUp() {\n        $this-&gt;setRootMenuPage(&#039;Post Timing&#039;);\n        $this-&gt;addSubMenuItems(\n            array(\n                &#039;title&#039;     =&gt; &#039;Setup Time&#039;,\n                &#039;page_slug&#039; =&gt; &#039;schedule_settings&#039;,\n            ),\n            array(\n                &#039;title&#039;     =&gt; &#039;Queue&#039;,\n                &#039;page_slug&#039; =&gt; &#039;schedule_queue&#039;,\n            )\n        );\n    }\n    \n}\nnew ScheduleMenu();<\/code><\/pre>\n<p>index.php:<\/p>\n<pre><code>define(&quot;SCHEDULE_PLUGIN_DIR&quot;, trailingslashit(dirname(__FILE__)));\ndefine(&quot;SCHEDULE_PLUGIN_URL&quot;, trailingslashit(plugin_dir_url(__FILE__)));\nrequire_once SCHEDULE_PLUGIN_DIR . &quot;functions.php&quot;;\nrequire_once SCHEDULE_PLUGIN_DIR . &quot;admin\/admin-menu.php&quot;;<\/code><\/pre>\n","protected":false},"template":"","class_list":["post-13734810","topic","type-topic","status-publish","hentry"],"jetpack_sharing_enabled":true,"_links":{"self":[{"href":"https:\/\/wordpress.org\/support\/wp-json\/wp\/v2\/topic\/13734810","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":0,"href":"https:\/\/wordpress.org\/support\/wp-json\/wp\/v2\/topic\/13734810\/revisions"}],"wp:attachment":[{"href":"https:\/\/wordpress.org\/support\/wp-json\/wp\/v2\/media?parent=13734810"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}