advanced custom fields – Update ACF 5.10.2 to ACF 6.0


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 () {
add_action(‘acf/init’, function () {

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

as they contain :

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

codingteam 1 month 2023-01-03T11:29:38-05:00 0 Answers 0 views 0

Leave an answer