From 4057b6793a020d1cd85782e4f0cec7ff4bab83f0 Mon Sep 17 00:00:00 2001 From: Erick Hitter <git-contrib@ethitter.com> Date: Sun, 26 Jun 2022 21:55:34 -0700 Subject: [PATCH] PHPCS --- automatically-paginate-posts.php | 2 +- inc/class-block-editor.php | 4 ++-- phpcs.xml | 3 +-- 3 files changed, 4 insertions(+), 5 deletions(-) diff --git a/automatically-paginate-posts.php b/automatically-paginate-posts.php index 6214ff6..4984fab 100644 --- a/automatically-paginate-posts.php +++ b/automatically-paginate-posts.php @@ -180,7 +180,7 @@ class Automatically_Paginate_Posts { if ( ! did_action( 'init' ) ) { _doing_it_wrong( __METHOD__, - __( + esc_html__( 'Post types can only be retrieved after the "init" hook.', 'autopaging' ), diff --git a/inc/class-block-editor.php b/inc/class-block-editor.php index 32ebb28..f6e47e4 100644 --- a/inc/class-block-editor.php +++ b/inc/class-block-editor.php @@ -133,9 +133,9 @@ class Block_Editor { wp_localize_script( $asset_handle, 'autopagingSettings', - [ + array( 'metaKey' => $this->autopaging_instance->meta_key, - ] + ) ); wp_set_script_translations( diff --git a/phpcs.xml b/phpcs.xml index c7914ff..af32422 100644 --- a/phpcs.xml +++ b/phpcs.xml @@ -4,9 +4,8 @@ <!-- What to scan --> <file>.</file> - <exclude-pattern>/vendor/</exclude-pattern> + <exclude-pattern>/assets/build/</exclude-pattern> <exclude-pattern>/node_modules/</exclude-pattern> - <exclude-pattern>/tests/*</exclude-pattern> <!-- How to scan --> <!-- Usage instructions: https://github.com/squizlabs/PHP_CodeSniffer/wiki/Usage --> -- GitLab