Home › Forums › Bug Reports › undefined function get_current_screen() › Reply To: undefined function get_current_screen()
Hi guys
Thanks for the bug report.
I have found and fixed hit bug and will release a new version later today. For now, please edit the api/api-helpers.php
file ~line 3310 and replace the function acf_is_screen
with this:
function acf_is_screen( $id = '' ) {
// bail early if not defined
if( !function_exists('get_current_screen') ) return false;
// vars
$current_screen = get_current_screen();
// bail early if no screen
if( !$current_screen ) return false;
// return
return ($id === $current_screen->id);
}
Thanks
Elliot
Welcome to the Advanced Custom Fields community forum.
Browse through ideas, snippets of code, questions and answers between fellow ACF users
Helping others is a great way to earn karma, gain badges and help ACF development!
We use cookies to offer you a better browsing experience, analyze site traffic and personalize content. Read about how we use cookies and how you can control them in our Privacy Policy. If you continue to use this site, you consent to our use of cookies.