Plugin Directory

Changeset 3343925


Ignore:
Timestamp:
08/13/2025 06:00:56 AM (7 months ago)
Author:
xfive
Message:

minor fixes and adjustments

Location:
xfive-sentry-integration/trunk/inc
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • xfive-sentry-integration/trunk/inc/Helper/PluginHelpers.php

    r3343611 r3343925  
    104104    public static function is_admin_area() {
    105105        if ( is_admin() ) {
    106             $page = isset( $_GET['page'] ) ? sanitize_text_field( wp_unslash( $_GET['page'] ) ) : ''; // phpcs:ignore -- verified by wp.
     106            $page = isset( $_GET['page'] ) ? sanitize_text_field( wp_unslash( $_GET['page'] ) ) : '';
    107107
    108108            return $page !== XFIVE_SENTRY_SLUG;
  • xfive-sentry-integration/trunk/inc/Service/Sentry.php

    r3343524 r3343925  
    111111            }
    112112
    113             $exceptions = $event->getExceptions();
     113            $exceptions  = $event->getExceptions();
     114            $should_stop = false;
    114115
    115116            if ( $exceptions ) {
     
    123124                            $normalized_file = str_replace( '\\', '/', $file );
    124125
    125                             if ( strpos( $normalized_file, '/wp-content/plugins/' ) !== false ) {
    126                                 // Skip this error – it's from a plugin.
    127                                 return null;
     126                            if ( strpos( $normalized_file, '/wp-content/plugins/' ) !== false && strpos( $normalized_file, '/wp-content/plugins/' . XFIVE_SENTRY_SLUG ) === false ) {
     127                                $should_stop = true;
     128                                break;
    128129                            }
    129130                        }
    130131                    }
    131132                }
     133            }
     134
     135            if ( $should_stop ) {
     136                return null;
    132137            }
    133138
Note: See TracChangeset for help on using the changeset viewer.