Support » Plugin: ACF Photo Gallery Field » Error after upgrading to 1.6.3

  • Resolved rkajbaf

    (@rkajbaf)


    After upgrading, I get the following error on all JSON calls I had to deactivate the plugin. Any help is greatly appreciated.

    <br />
    <b>Fatal error</b>: Uncaught Error: Call to a member function get_params() on array in /var/www/vhosts/site/wp-content/plugins/navz-photo-gallery/navz-photo-gallery.php:100
    Stack trace:
    #0 /var/www/vhosts/site/wp-includes/class-wp-hook.php(286): acf_plugin_photo_gallery->acf_to_rest_api(Array, Array)
    #1 /var/www/vhosts/site/wp-includes/plugin.php(203): WP_Hook->apply_filters(Array, Array)
    #2 /var/www/vhosts/site/wp-content/plugins/acf-to-rest-api/v3/lib/class-acf-to-rest-api-acf-api.php(107): apply_filters(‘acf/rest_api/pa…’, Array, Array)
    #3 /var/www/vhosts/site/wp-content/plugins/acf-to-rest-api/v3/lib/endpoints/class-acf-to-rest-api-controller.php(62): ACF_To_REST_API_ACF_API->get_fields(Array)
    #4 /var/www/vhosts/site/wp-includes/rest-api/endpoints/class-wp-rest-controller.php(394): ACF_To_REST_API_Controller->register_field_callback(Array, ‘acf’, Object(WP_REST_Request), ‘page’)
    #5 /var/www/vhosts/site in <b>/var/www/vhosts/site/wp-content/plugins/navz-photo-gallery/navz-photo-gallery.php</b> on line <b>100</b><br />

Viewing 2 replies - 1 through 2 (of 2 total)
  • Plugin Author Navneil Naicker

    (@navzme)

    Hi @rkajbaf
    I have updated the plugin documentation. WordPress was removing some parts of the documentation. Please change your code with the usage below, note that you will need to replace POST_ID and Field_Name with correct values.

    Usage 1
    http://www.example.com/wp-json/acf/v3/pages/POST_ID/Field_Name?type=photo_gallery

    Example
    http://www.example.com/wp-json/acf/v3/pages/2/vacation_photos?type=photo_gallery

    Please advise
    Thanks

    mattjcowan

    (@mattjcowan)

    I’m also unable to use the plugin. The following links both produce the error (php72):
    https://wp.covenantclassicalschool.org/wp-json/wp/v2/pages
    https://wp.covenantclassicalschool.org/wp-json/acf/v3/pages

    `
    <br />
    <b>Fatal error</b>: Uncaught Error: Call to a member function get_params() on array in C:\sites\wp.site\wp-content\plugins\navz-photo-gallery\navz-photo-gallery.php:100
    Stack trace:
    #0 C:\sites\wp.site\wp-includes\class-wp-hook.php(286): acf_plugin_photo_gallery->acf_to_rest_api(Array, Array)
    #1 C:\sites\wp.site\wp-includes\plugin.php(203): WP_Hook->apply_filters(Array, Array)
    #2 C:\sites\wp.site\wp-content\plugins\acf-to-rest-api\v3\lib\class-acf-to-rest-api-acf-api.php(107): apply_filters(‘acf/rest_api/pa…’, Array, Array)
    #3 C:\sites\wp.site\wp-content\plugins\acf-to-rest-api\v3\lib\endpoints\class-acf-to-rest-api-controller.php(62): ACF_To_REST_API_ACF_API->get_fields(Array)
    #4 C:\sites\wp.site\wp-includes\rest-api\endpoints\class-wp-rest-controller.php(394): ACF_To_REST_API_Controller->register_field_callback(Array, ‘acf’, Object(WP_REST_Request), ‘page’)
    #5 C:\sites\wp.site in <b>C:\sites\wp.site\wp-content\plugins\navz-photo-gallery\navz-photo-gallery.php</b> on line <b>100</b><br />
    `

Viewing 2 replies - 1 through 2 (of 2 total)
  • The topic ‘Error after upgrading to 1.6.3’ is closed to new replies.