Skip to content

Commit

Permalink
Apply suggestions from code review
Browse files Browse the repository at this point in the history
Co-authored-by: Weston Ruter <westonruter@google.com>
  • Loading branch information
mukeshpanchal27 and westonruter authored Oct 31, 2023
1 parent c202309 commit 0ef2476
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion includes/Traits/File_Editor_URL.php
Original file line number Diff line number Diff line change
Expand Up @@ -63,7 +63,7 @@ protected function get_file_editor_url( Check_Result $result, $filename, $line =
$editor_url_template = apply_filters( 'wp_plugin_check_validation_error_source_file_editor_url_template', null );

// Supply the file path to the editor template.
if ( null !== $editor_url_template && str_contains( $editor_url_template, '{{file}}' ) ) {
if ( is_string( $editor_url_template ) && str_contains( $editor_url_template, '{{file}}' ) ) {
$file_path = WP_PLUGIN_DIR . '/' . $plugin_slug;
if ( $plugin_slug !== $filename ) {
$file_path .= '/' . $filename;
Expand Down

0 comments on commit 0ef2476

Please sign in to comment.