94% plugin-install-notifier

Code Review | Plugin Notifier

WordPress plugin Plugin Notifier scored 94% from 54 tests.

About plugin

  • Plugin page: plugin-install-no...
  • Plugin version: 1.1
  • PHP compatiblity: 5.6+
  • PHP version: 7.4.16
  • WordPress compatibility: 3.9-4.9.1
  • WordPress version: 5.8.1
  • First release: Jan 18, 2018
  • Latest release: Jan 22, 2018
  • Number of updates: 10
  • Update frequency: every 0.4 days
  • Top authors: mdahlkewisnet (100%)

Code review

54 tests

User reviews

1 review

Install metrics

100+ active / 663 total downloads

Benchmarks

Plugin footprint Passed 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | All plugins must install correctly, without throwing any errors, warnings, or notices
The plugin installed gracefully, with no errors

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

Server-side resources used by Plugin Notifier
Server-side resource usage in normal parameters
PageMemory (MB)CPU Time (ms)
Home /2.86 ▲0.0343.65 ▲4.03
Dashboard /wp-admin3.09 ▲0.0352.42 ▲4.40
Posts /wp-admin/edit.php3.14 ▲0.0347.03 ▼9.35
Add New Post /wp-admin/post-new.php5.44 ▲0.0195.47 ▼569.77
Media Library /wp-admin/upload.php3.03 ▲0.0339.71 ▲0.16
Plugin Notifier /wp-admin/tools.php?page=plugin-notifier3.0032.92

Server storage [IO: ▲0.01MB] [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: 4 new files
Database: no new tables, no new options

Browser metrics Passed 4 tests

A check of browser resources used by Plugin Notifier
This plugin renders optimally with no browser resource issues detected
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /3,708 ▲13615.88 ▲0.3115.83 ▲4.2052.64 ▼3.64
Dashboard /wp-admin2,975 ▲475.91 ▼0.09175.01 ▲15.83110.84 ▼9.04
Posts /wp-admin/edit.php2,744 ▲52.72 ▼0.0075.34 ▲6.70103.87 ▲4.80
Add New Post /wp-admin/post-new.php1,686 ▲316.25 ▼2.14436.90 ▼10.78121.51 ▲0.06
Media Library /wp-admin/upload.php1,812 ▲55.01 ▼0.07168.62 ▼3.36131.40 ▲6.16
Plugin Notifier /wp-admin/tools.php?page=plugin-notifier1,0652.1060.1066.98

Uninstaller [IO: ▲0.00MB] [DB: ▲0.00MB] Passed 4 tests

🔸 Tests weight: 35 | Checking the uninstaller removed all traces of the plugin
The plugin uninstalled successfully, without leaving any zombie files or tables

Smoke tests 75% from 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | This is a shallow check for server-side errors
Everything seems fine, however this is by no means 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
Please take a closer look at the following
  • 2× GET requests to PHP files have triggered server-side errors or warnings:
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_action() in wp-content/plugins/plugin-install-notifier/plugin-install-notification.php:71
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_action() in wp-content/plugins/plugin-install-notifier/trunk/plugin-install-notification.php:71

User-side errors Passed 1 test

🔹 Test weight: 20 | This is just a short smoke test looking for browser issues
Everything seems fine, but this is not an exhaustive test

Optimizations

Plugin configuration 96% from 29 tests

readme.txt Passed 16 tests

The readme.txt file is important because it is parsed by WordPress.org for the public listing of your plugin
2 plugin tags: notifications, plugins

plugin-install-notifier/plugin-install-notification.php 92% from 13 tests

The main file in "Plugin Notifier" v. 1.1 serves as a complement to information provided in readme.txt and as the entry point to the plugin
Please make the necessary changes and fix the following:
  • Main file name: Even though not officially enforced, the main plugin file should be the same as the plugin slug ("plugin-install-notifier.php" instead of "plugin-install-notification.php")

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | An overview of files in this plugin; executable files are not allowed
Success! There were no dangerous files found in this plugin280 lines of code in 2 files:
LanguageFilesBlank linesComment linesLines of code
PHP24216280

PHP code Passed 2 tests

Analyzing cyclomatic complexity and code structure
This plugin has no cyclomatic complexity problems
Cyclomatic complexity
Average complexity per logical line of code0.18
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%
Functions14
▷ Named functions642.86%
▷ Anonymous functions857.14%
Constants2
▷ Global constants2100.00%
▷ Class constants00.00%
▷ Public constants00.00%

Plugin size Passed 2 tests

Image compression Passed 2 tests

All PNG images should be compressed to minimize bandwidth usage for end users
PNG images were not found in this plugin