Skip to content

Commit

Permalink
Ignore PHPCS warnings
Browse files Browse the repository at this point in the history
  • Loading branch information
dkotter committed Dec 10, 2024
1 parent c7f879a commit 295b3d4
Show file tree
Hide file tree
Showing 4 changed files with 8 additions and 1 deletion.
3 changes: 3 additions & 0 deletions includes/Classifai/Admin/Notifications.php
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
<?php
/* phpcs:disable PluginCheck.CodeAnalysis.ImageFunctions.NonEnqueuedImage */

namespace Classifai\Admin;

Expand Down Expand Up @@ -280,6 +281,7 @@ public function add_dismiss_script() {
$nonce = wp_create_nonce( 'classifai_dismissible_notice' );
$admin_ajax_url = esc_url( admin_url( 'admin-ajax.php' ) );

/* phpcs:disable Squiz.PHP.Heredoc.NotAllowed */
$script = <<<EOD
jQuery( function() {
const dismissNotices = document.querySelectorAll( '.classifai-dismissible-notice' );
Expand Down Expand Up @@ -314,6 +316,7 @@ public function add_dismiss_script() {
});
});
EOD;
/* phpcs:enable Squiz.PHP.Heredoc.NotAllowed */

wp_add_inline_script( 'common', $script, 'after' );
}
Expand Down
2 changes: 2 additions & 0 deletions includes/Classifai/Admin/templates/classifai-header.php
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,8 @@
* @package ClassifAI
*/

/* phpcs:disable PluginCheck.CodeAnalysis.ImageFunctions.NonEnqueuedImage */

// phpcs:ignore WordPress.Security.NonceVerification.Recommended
$active_page = isset( $_GET['tab'] ) ? sanitize_text_field( wp_unslash( $_GET['tab'] ) ) : 'classifai_settings';
// phpcs:ignore WordPress.Security.NonceVerification.Recommended
Expand Down
2 changes: 2 additions & 0 deletions includes/Classifai/Admin/templates/onboarding-header.php
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,8 @@
* @package ClassifAI
*/

/* phpcs:disable PluginCheck.CodeAnalysis.ImageFunctions.NonEnqueuedImage */

/** @var array $args Arguments coming from the included file. */
?>
<h1 class="classifai-setup-heading">
Expand Down
2 changes: 1 addition & 1 deletion includes/Classifai/Features/ImageGeneration.php
Original file line number Diff line number Diff line change
Expand Up @@ -331,7 +331,7 @@ public function print_media_templates() {

<?php
// Template for a single generated image.
/* phpcs:disable WordPressVIPMinimum.Security.Mustache.OutputNotation */
/* phpcs:disable WordPressVIPMinimum.Security.Mustache.OutputNotation,PluginCheck.CodeAnalysis.ImageFunctions.NonEnqueuedImage */
?>
<script type="text/html" id="tmpl-dalle-image">
<div class="generated-image">
Expand Down

0 comments on commit 295b3d4

Please sign in to comment.