78% gmo-ads-master

Code Review | Plugin Name: GMO Ads Master

WordPress plugin Plugin Name: GMO Ads Master scored78%from 54 tests.

About plugin

  • Plugin page: gmo-ads-master
  • Plugin version: 1.3
  • PHP version: 7.4.16
  • WordPress compatibility: 3.8.1-4.4
  • WordPress version: 6.3.1
  • First release: Apr 14, 2014
  • Latest release: Jan 29, 2016
  • Number of updates: 39
  • Update frequency: every 29.0 days
  • Top authors: Takeaki Nagashima (100%)

Code review

54 tests

User reviews

1 review

Install metrics

10+ active /1,610 total downloads

Benchmarks

Plugin footprint 83% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | Checking the installer triggered no errors
Installer ran successfully

Server metrics [RAM: ▲0.03MB] [CPU: ▼6.23ms] Passed 4 tests

Analyzing server-side resources used by Plugin Name: GMO Ads Master
This plugin has minimal impact on server resources
PageMemory (MB)CPU Time (ms)
Home /3.51 ▲0.0441.38 ▼2.41
Dashboard /wp-admin3.34 ▲0.0349.84 ▲0.78
Posts /wp-admin/edit.php3.39 ▲0.0347.34 ▼5.41
Add New Post /wp-admin/post-new.php5.92 ▲0.0386.64 ▼17.87
Media Library /wp-admin/upload.php3.26 ▲0.0336.85 ▲3.53
GMO Ads Master /wp-admin/options-general.php?page=gmoadsmaster3.2333.07

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

Filesystem and database footprint
The plugin installed successfully
Filesystem: 30 new files
Database: no new tables, 8 new options
New WordPress options
can_compress_scripts
gmoadsmaster_activation
theysaidso_admin_options
widget_recent-posts
widget_gmo_ad_widget
widget_recent-comments
db_upgraded
widget_theysaidso_widget

Browser metrics Passed 4 tests

Plugin Name: GMO Ads Master: an overview of browser usage
Normal browser usage
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,795 ▲914.69 ▲0.071.87 ▲0.1043.20 ▼4.85
Dashboard /wp-admin2,193 ▲165.51 ▼0.1084.36 ▼11.4039.46 ▼3.67
Posts /wp-admin/edit.php2,104 ▲42.00 ▼0.0133.43 ▼9.0640.71 ▲3.32
Add New Post /wp-admin/post-new.php1,531 ▼623.19 ▲5.04653.20 ▲8.9467.72 ▲3.63
Media Library /wp-admin/upload.php1,401 ▲44.19 ▼0.02102.54 ▼0.2244.01 ▲2.39
GMO Ads Master /wp-admin/options-general.php?page=gmoadsmaster1,0032.1723.6128.21

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

🔸 Tests weight: 35 | Checking the uninstaller removed all traces of the plugin
It is recommended to fix the following
  • The uninstall procedure has failed, leaving 7 options in the database
    • can_compress_scripts
    • db_upgraded
    • widget_recent-posts
    • widget_gmo_ad_widget
    • theysaidso_admin_options
    • widget_theysaidso_widget
    • 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)
Everything seems fine, however this is by no means an exhaustive test

SRP 50% from 2 tests

🔹 Tests weight: 20 | A shallow check of the single-responsibility principle; PHP files should perform no action - including output of placeholder text - and trigger no errors when accessed directly
Almost there! Just fix the following items
  • 2× PHP files trigger errors when accessed directly with GET requests:
    • > PHP Fatal error
      Uncaught Error: Call to undefined function plugins_url() in wp-content/plugins/gmo-ads-master/gmo-ads-master.php:33
    • > PHP Fatal error
      Uncaught Error: Class 'WP_Widget' not found in wp-content/plugins/gmo-ads-master/includes/gmo_ad_widget.php:9

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 take a look at the following user-side issues
    • > GET request to /wp-admin/options-general.php?page=gmoadsmaster
    • > Network (severe)
    wp-content/plugins/gmo-ads-master/images/bnr_themes.png - Failed to load resource: the server responded with a status of 404 (Not Found)
    • > GET request to /wp-admin/options-general.php?page=gmoadsmaster
    • > Network (severe)
    wp-content/plugins/gmo-ads-master/css/gmo-admin-plugin.css?ver=6.3.1 - Failed to load resource: the server responded with a status of 404 (Not Found)
    • > GET request to /wp-admin/options-general.php?page=gmoadsmaster
    • > Network (severe)
    wp-content/plugins/gmo-ads-master/images/bnr_plugins.png - Failed to load resource: the server responded with a status of 404 (Not Found)
    • > GET request to /wp-admin/options-general.php?page=gmoadsmaster
    • > Network (severe)
    wp-content/plugins/gmo-ads-master/images/logo.png - Failed to load resource: the server responded with a status of 404 (Not Found)

Optimizations

Plugin configuration 90% from 29 tests

readme.txt 94% from 16 tests

The readme.txt file is an important file in your plugin as it is parsed by WordPress.org to prepare the public listing of your plugin
Attributes that require attention:
  • Plugin Name: Please specify the plugin name on the first line ( === Plugin Name: GMO Ads Master === )
You can look at the official readme.txt

gmo-ads-master/gmo-ads-master.php 85% from 13 tests

The principal PHP file in "Plugin Name: GMO Ads Master" v. 1.3 is loaded by WordPress automatically on each request
It is important to fix the following:
  • Description: Keep the plugin description shorter than 140 characters (currently 325 characters long)
  • Text Domain: The text domain is optional since WordPress version 4.6; if you do specify it, it must be the same as the plugin slug

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | A short glimpse at programming languages used with this plugin and a check that no dangerous files are present
There were no executable files found in this plugin656 lines of code in 17 files:
LanguageFilesBlank linesComment linesLines of code
PHP38138445
Sass2250109
XML50036
JavaScript151235
JSON10025
CSS4194
Markdown1102

PHP code Passed 2 tests

This plugin's cyclomatic complexity and code structure detailed below
No complexity issues detected
Cyclomatic complexity
Average complexity per logical line of code0.21
Average class complexity16.00
▷ Minimum class complexity15.00
▷ Maximum class complexity17.00
Average method complexity2.20
▷ Minimum method complexity1.00
▷ Maximum method complexity13.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes2
▷ Abstract classes00.00%
▷ Concrete classes2100.00%
▷ Final classes00.00%
Methods25
▷ Static methods00.00%
▷ Public methods2184.00%
▷ Protected methods00.00%
▷ Private methods416.00%
Functions3
▷ Named functions3100.00%
▷ Anonymous functions00.00%
Constants3
▷ Global constants3100.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
8 PNG files occupy 0.24MB with 0.13MB in potential savings
Potential savings
Compression of 5 random PNG files using pngquant
FileSize - originalSize - compressedSavings
images/wpshop_logo.png7.22KB5.91KB▼ 18.12%
images/wpcloud_bnr_plugins.png9.14KB4.07KB▼ 55.50%
images/wpshop_bnr_themes.png13.39KB5.79KB▼ 56.74%
images/ico_link.png1.00KB0.21KB▼ 79.07%
images/wpshop_bnr_plugins.png13.29KB5.68KB▼ 57.23%