10% responsive-notifications

Code Review | Responsive Notifications

WordPress plugin Responsive Notifications scored 10% from 54 tests.

About plugin

  • Plugin page: responsive-notifi...
  • Plugin version: ...
  • PHP version: 7.4.16
  • WordPress compatibility: 3.0-3.9.2
  • WordPress version: 5.9.2
  • First release: Dec 24, 2014
  • Latest release: Dec 29, 2014
  • Number of updates: 4
  • Update frequency: every 4.3 days
  • Top authors: goresponsive (100%)

Code review

54 tests

User reviews

3 reviews

Install metrics

10+ active / 6,940 total downloads

Benchmarks

Plugin footprint 40% from 16 tests

Installer 0% from 1 test

🔺 Critical test (weight: 50) | It is important to correctly install your plugin, without throwing errors or notices
You still need to fix the following installer errors
  • Install procedure validation failed for this plugin
    • > Deprecated in wp-content/plugins/responsive-notifications/notify.php+35
    Methods with the same name as their class will not be constructors in a future version of PHP; go_notification_styles has a deprecated constructor

Server metrics [RAM: ▼2.36MB] [CPU: ▼367.53ms] Passed 4 tests

This is a short check of server-side resources used by Responsive Notifications
No issues were detected with server-side resource usage
PageMemory (MB)CPU Time (ms)
Home /2.01 ▼1.517.78 ▼53.51
Dashboard /wp-admin2.03 ▼1.387.33 ▼35.53
Posts /wp-admin/edit.php2.03 ▼1.627.07 ▼44.38
Add New Post /wp-admin/post-new.php2.03 ▼4.958.07 ▼1,336.69
Media Library /wp-admin/upload.php2.03 ▼1.277.82 ▼29.19

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

Input-output and database impact of this plugin
This plugin was installed successfully
Filesystem: 23 new files
Database: no new tables, 1 new option
New WordPress options
widget_go_notification_styles

Browser metrics Passed 4 tests

This is an overview of browser requirements for Responsive Notifications
This plugin has a minimal impact on browser resources
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /3,851 ▲9716.03 ▲0.509.24 ▲0.983.73 ▲0.61
Dashboard /wp-admin2,954 ▲356.42 ▼0.02179.32 ▼21.90199.95 ▼12.72
Posts /wp-admin/edit.php2,718 ▼03.42 ▼0.0185.23 ▼7.15178.79 ▼1.87
Add New Post /wp-admin/post-new.php1,613 ▼4922.00 ▲5.08636.19 ▼64.21229.97 ▲32.14
Media Library /wp-admin/upload.php1,730 ▲15.70 ▼0.01189.43 ▼13.25258.56 ▲19.53

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

🔸 Tests weight: 35 | Checking the uninstaller removed all traces of the plugin
Please fix the following items
  • This plugin did not uninstall without warnings or errors
    • > User deprecated in wp-includes/functions.php+5409
    The called constructor method for WP_Widget in go_notification_styles is deprecated since version 4.3.0! Use __construct() instead.
  • The uninstall procedure has failed, leaving 1 option in the database
    • widget_go_notification_styles

Smoke tests 75% from 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | A smoke test targeting server-side errors
The smoke test was a success, however most plugin functionality was not tested

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
  • 1× GET requests to PHP files trigger server-side errors or Error 500 responses:
    • > PHP Fatal error
      Uncaught Error: Call to undefined function plugin_dir_url() in wp-content/plugins/responsive-notifications/notify.php:13

User-side errors Passed 1 test

🔹 Test weight: 20 | Just a short smoke test targeting errors on the browser (console and network errors and warnings)
No browser errors were detected

Optimizations

Plugin configuration 90% from 29 tests

readme.txt 94% from 16 tests

The readme.txt file describes your plugin functionality and requirements and it is parsed to prepare the your plugin's listing
These attributes need your attention:
  • Screenshots: Please add images for these screenshots: #1 (screenshot-1.png - One of the responsive notification types), #2 (screenshot-2.png - One of the responsive notification types), #3 (screenshot-3.png - One of the responsive notification types), #4 (screenshot-4.png - One of the responsive notification types), #5 (screenshot-5.png - One of the responsive notification types), #6 (screenshot-6.png - One of the responsive notification types), #7 (screenshot-7.png - One of the responsive notification types), #8 (screenshot-8.png - One of the responsive notification types), #9 (screenshot-9.png - One of the responsive notification types), #10 (screenshot-10.png - One of the responsive notification types), #11 (screenshot-11.png - One of the responsive notification types)
The official readme.txt is a good inspiration

responsive-notifications/notify.php 85% from 13 tests

Analyzing the main PHP file in "Responsive Notifications" version ...
You should first fix the following items:
  • Main file name: The principal plugin file should be the same as the plugin slug ("responsive-notifications.php" instead of "notify.php")
  • Version: The version number should be digits and periods (ex. "1.0.3" instead of "...")

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 plugin2,247 lines of code in 11 files:
LanguageFilesBlank linesComment linesLines of code
CSS5204301,433
PHP2135106676
JavaScript42899138

PHP code Passed 2 tests

This plugin's cyclomatic complexity and code structure detailed below
No cyclomatic complexity issues were detected for this plugin
Cyclomatic complexity
Average complexity per logical line of code0.30
Average class complexity43.00
▷ Minimum class complexity43.00
▷ Maximum class complexity43.00
Average method complexity11.50
▷ Minimum method complexity1.00
▷ Maximum method complexity28.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes1
▷ Abstract classes00.00%
▷ Concrete classes1100.00%
▷ Final classes00.00%
Methods4
▷ Static methods00.00%
▷ Public methods4100.00%
▷ Protected methods00.00%
▷ Private methods00.00%
Functions5
▷ Named functions5100.00%
▷ Anonymous functions00.00%
Constants1
▷ Global constants1100.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
11 compressed PNG files occupy 0.48MB
Potential savings
Compression of 5 random PNG files using pngquant
FileSize - originalSize - compressedSavings
screenshot-1.png44.03KB42.98KB▼ 2.38%
screenshot-4.png44.80KB43.83KB▼ 2.17%
screenshot-2.png40.75KB40.29KB▼ 1.12%
screenshot-10.png49.26KB47.77KB▼ 3.02%
screenshot-5.png35.04KB34.66KB▼ 1.09%