Remove one-time variable from add_settings_error().
props niallkennedy. fixes #22228. Built from https://develop.svn.wordpress.org/trunk@28681 git-svn-id: http://core.svn.wordpress.org/trunk@28499 1a063a9b-81f0-0310-95a4-ce76da25c4cd
This commit is contained in:
parent
ce508e95c2
commit
4b14fe0593
|
@ -1298,13 +1298,12 @@ function do_settings_fields($page, $section) {
|
|||
function add_settings_error( $setting, $code, $message, $type = 'error' ) {
|
||||
global $wp_settings_errors;
|
||||
|
||||
$new_error = array(
|
||||
$wp_settings_errors[] = array(
|
||||
'setting' => $setting,
|
||||
'code' => $code,
|
||||
'code' => $code,
|
||||
'message' => $message,
|
||||
'type' => $type
|
||||
'type' => $type
|
||||
);
|
||||
$wp_settings_errors[] = $new_error;
|
||||
}
|
||||
|
||||
/**
|
||||
|
|
Loading…
Reference in New Issue