Support

Account

Home Forums ACF PRO Update ACF

Helping

Update ACF

  • Hello,
    I am updating ACF from 5.10.2 to 6.0.6 , I am getting this error :
    Notice: acf_get_value was called incorrectly. Advanced Custom Fields PRO - We've detected one or more calls to retrieve ACF field values before ACF has been initialized. This is not supported and can result in malformed or missing data.

    I have tried many methods to solve the problem but none of them has worked :
    For example : changing get_field(‘qsef’,’options’) and get_field(‘rfr’,’option’) to get_option(‘fezf’);
    in setup.php
    and changing for example

    In setup.php
    replacing :
    add_action(‘init’, function () {
    to
    add_action(‘acf/init’, function () {

    and add_action(‘wp’,function
    to add_action(‘acf/init’,function

    as they contain :
    acf_add_local_field_group(

    I have tried but I did not reach any solution to debug this problem ,
    Do anyone has an idea about this?
    Thanks in advance

  • This only happens when trying to get a field

    • before ACF is initialized
    • that is not defined by ACF

    Yes, these issues can be hard to track down and it’s very difficult to give advice on where to look.

Viewing 2 posts - 1 through 2 (of 2 total)

You must be logged in to reply to this topic.