Skip to content

Commit 25672a3

Browse files
authored
Merge pull request #667 from Automattic/fix/pass-variable-reference
Fixes non-variable being passed by reference
2 parents 2f9d9f5 + 17c773b commit 25672a3

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

common/php/screen-options.php

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -166,7 +166,8 @@ function ajax_save_callback(){
166166
}
167167

168168
//The 'action' argument is in the form "save_settings-panel_id"
169-
$id = end(explode('-', $_POST['action'], 2));
169+
$ids = explode( '-', $_POST['action'], 2 );
170+
$id = end( $ids );
170171

171172
//Basic security check.
172173
check_ajax_referer('save_settings-' . $id, '_wpnonce-' . $id);

0 commit comments

Comments
 (0)