Skip to content

Commit

Permalink
Merge pull request #1 from frc/hotfix/current-screen-undefined
Browse files Browse the repository at this point in the history
bail early if get_current_screen() not defined
  • Loading branch information
Sanna authored Feb 4, 2022
2 parents 909fb44 + 08aaf77 commit 4992012
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions multilingual-options-page.php
Original file line number Diff line number Diff line change
Expand Up @@ -78,6 +78,10 @@ public function acf_location_rules_values($choices) {
}

public function acf_location_rules_match($match, $rule, $options) {
if (!function_exists('get_current_screen')) {
return;
}

$selected_options_page = $rule['value'];
$current_screen = get_current_screen();

Expand Down

0 comments on commit 4992012

Please sign in to comment.