From 235c360cea4eb42fbb3389d348cc7392a2b055ae Mon Sep 17 00:00:00 2001 From: Erick Hitter <services@ethitter.com> Date: Tue, 28 Feb 2017 17:55:15 -0800 Subject: [PATCH] Don't use a foreach It's more lines of code and harder to decifer. But that was a fun exercise. --- includes/class-main.php | 2 -- 1 file changed, 2 deletions(-) diff --git a/includes/class-main.php b/includes/class-main.php index 7d594e8..b9500e5 100644 --- a/includes/class-main.php +++ b/includes/class-main.php @@ -71,8 +71,6 @@ class Main { private static function capture_vars() { $vars = (object) array_fill_keys( array( 'user_id', 'action', 'post_type', 'posts', 'tax_input', 'post_author', 'comment_status', 'ping_status', 'post_status', 'post_sticky', 'post_format', ), null ); - // TODO: replace with foreach and switch - $vars->user_id = get_current_user_id(); if ( isset( $_REQUEST['delete_all'] ) ) { -- GitLab