78% fraud-gmail-filter

Code Review | Fraud Gmail Filter

WordPress plugin Fraud Gmail Filter scored 78% from 54 tests.

About plugin

  • Plugin page: fraud-gmail-filter
  • Plugin version: 0.0.3
  • PHP version: 7.4.16
  • WordPress compatibility: 4.0-4.1
  • WordPress version: 6.3.1
  • First release: Sep 13, 2014
  • Latest release: Dec 17, 2014
  • Number of updates: 10
  • Update frequency: every 9.6 days
  • Top authors: saaiful (100%)

Code review

54 tests

User reviews

1 review

Install metrics

10+ active / 747 total downloads

Benchmarks

Plugin footprint 83% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | It is important to correctly install your plugin, without throwing errors or notices
The plugin installed gracefully, with no errors

Server metrics [RAM: ▲0.02MB] [CPU: ▼3.66ms] Passed 4 tests

Analyzing server-side resources used by Fraud Gmail Filter
Server-side resource usage in normal parameters
PageMemory (MB)CPU Time (ms)
Home /3.48 ▲0.0238.36 ▼1.03
Dashboard /wp-admin3.32 ▲0.0246.37 ▼2.89
Posts /wp-admin/edit.php3.37 ▲0.0249.67 ▲2.32
Add New Post /wp-admin/post-new.php5.90 ▲0.0282.24 ▼13.05
Media Library /wp-admin/upload.php3.25 ▲0.0240.81 ▲3.94
FGF Settings /wp-admin/options-general.php?page=fraud-gmail-filter/fraud_gmail.php3.2131.43

Server storage [IO: ▲0.00MB] [DB: ▲0.00MB] Passed 3 tests

How much does this plugin use your filesystem and database?
There were no storage issued detected upon installing this plugin
Filesystem: 2 new files
Database: no new tables, 6 new options
New WordPress options
widget_theysaidso_widget
db_upgraded
theysaidso_admin_options
widget_recent-posts
can_compress_scripts
widget_recent-comments

Browser metrics Passed 4 tests

A check of browser resources used by Fraud Gmail Filter
There were no issues detected in relation to browser resource usage
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,812 ▲7713.28 ▼1.111.76 ▲0.1642.53 ▼5.70
Dashboard /wp-admin2,215 ▲245.80 ▼0.08105.74 ▲5.4338.88 ▼8.09
Posts /wp-admin/edit.php2,101 ▲122.01 ▼0.0240.75 ▲0.4438.00 ▲7.02
Add New Post /wp-admin/post-new.php1,678 ▲14522.47 ▼0.77651.06 ▼9.8168.04 ▲4.28
Media Library /wp-admin/upload.php1,400 ▲184.19 ▲0.0496.70 ▼10.4948.35 ▲3.33
FGF Settings /wp-admin/options-general.php?page=fraud-gmail-filter/fraud_gmail.php7932.0627.9532.21

Uninstaller [IO: ▲0.00MB] [DB: ▲0.00MB] 75% from 4 tests

🔸 Tests weight: 35 | Verifying that this plugin uninstalls completely without leaving any traces
The following items require your attention
  • Zombie WordPress options detected upon uninstall: 6 options
    • widget_recent-posts
    • can_compress_scripts
    • widget_theysaidso_widget
    • db_upgraded
    • theysaidso_admin_options
    • widget_recent-comments

Smoke tests 50% from 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | Just a short smoke test targeting errors on the server (in the Apache logs)
Even though everything seems fine, this is not an exhaustive test

SRP 50% from 2 tests

🔹 Tests weight: 20 | The single-responsibility principle: PHP files have to remain inert when accessed directly, throwing no errors and performing no actions
The following issues need your attention
  • 1× PHP files trigger errors when accessed directly with GET requests:
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_filter() in wp-content/plugins/fraud-gmail-filter/fraud_gmail.php:40

User-side errors 0% from 1 test

🔹 Test weight: 20 | Just a short smoke test targeting errors on the browser (console and network errors and warnings)
Please fix the following browser errors
    • > GET request to /wp-admin/options-general.php?page=fraud-gmail-filter/fraud_gmail.php
    • > Network (severe)
    https://getbootstrap.com/assets/css/docs.min.css?ver=6.3.1 - Failed to load resource: the server responded with a status of 404 ()

Optimizations

Plugin configuration 93% from 29 tests

readme.txt 94% from 16 tests

Perhaps the most important file in your plugin readme.txt gets parsed in order to generate the public listing of your plugin
Please fix the following attributes:
  • Donate link: Invalid URI ("")
The official readme.txt might help

fraud-gmail-filter/fraud_gmail.php 92% from 13 tests

The primary PHP file in "Fraud Gmail Filter" version 0.0.3 is used by WordPress to initiate all plugin functionality
Please take the time to fix the following:
  • Main file name: Even though not officially enforced, the main plugin file should be the same as the plugin slug ("fraud-gmail-filter.php" instead of "fraud_gmail.php")

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | There should be no dangerous file extensions present in any WordPress plugin
Success! There were no dangerous files found in this plugin64 lines of code in 1 file:
LanguageFilesBlank linesComment linesLines of code
PHP1151164

PHP code Passed 2 tests

An short overview of logical lines of code, cyclomatic complexity, and other code metrics
There are no cyclomatic complexity problems detected for this plugin
Cyclomatic complexity
Average complexity per logical line of code0.17
Average class complexity0.00
▷ Minimum class complexity0.00
▷ Maximum class complexity0.00
Average method complexity0.00
▷ Minimum method complexity0.00
▷ Maximum method complexity0.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes0
▷ Abstract classes00.00%
▷ Concrete classes00.00%
▷ Final classes00.00%
Methods0
▷ Static methods00.00%
▷ Public methods00.00%
▷ Protected methods00.00%
▷ Private methods00.00%
Functions6
▷ Named functions6100.00%
▷ Anonymous functions00.00%
Constants0
▷ Global constants00.00%
▷ Class constants00.00%
▷ Public constants00.00%

Plugin size Passed 2 tests

Image compression Passed 2 tests

PNG files should be compressed to save space and minimize bandwidth usage
There are no PNG files in this plugin