89% ninja-toastify

Code Review | Ninja Toastify

WordPress plugin Ninja Toastify scored89%from 54 tests.

About plugin

  • Plugin page: ninja-toastify
  • Plugin version: 1.0.1
  • PHP compatiblity: 7.2+
  • PHP version: 7.4.16
  • WordPress compatibility: 5.2-6.2
  • WordPress version: 6.3.1
  • First release: Jul 23, 2023
  • Latest release: Aug 10, 2023
  • Number of updates: 24
  • Update frequency: every 0.8 days
  • Top authors: iamfarhan09 (100%)

Code review

54 tests

User reviews

1 review

Install metrics

10+ active /157 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
Install script ran successfully

Server metrics [RAM: ▲0.04MB] [CPU: ▼1.40ms] Passed 4 tests

A check of server-side resources used by Ninja Toastify
No issues were detected with server-side resource usage
PageMemory (MB)CPU Time (ms)
Home /3.51 ▲0.0539.64 ▲3.03
Dashboard /wp-admin3.34 ▲0.0445.96 ▼1.70
Posts /wp-admin/edit.php3.39 ▲0.0449.02 ▼0.49
Add New Post /wp-admin/post-new.php5.92 ▲0.0489.42 ▼6.43
Media Library /wp-admin/upload.php3.26 ▲0.0443.86 ▲10.04

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

Analyzing filesystem and database footprints of this plugin
There were no storage issued detected upon installing this plugin
Filesystem: 22 new files
Database: no new tables, 6 new options
New WordPress options
widget_recent-posts
widget_theysaidso_widget
can_compress_scripts
theysaidso_admin_options
widget_recent-comments
db_upgraded

Browser metrics Passed 4 tests

Checking browser requirements for Ninja Toastify
Normal browser usage
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,940 ▲20514.33 ▼0.0427.90 ▲26.1251.14 ▲9.90
Dashboard /wp-admin2,217 ▲285.86 ▲0.92100.66 ▼6.2978.34 ▲35.80
Posts /wp-admin/edit.php2,100 ▲111.99 ▼0.0139.49 ▼2.9439.91 ▲6.34
Add New Post /wp-admin/post-new.php1,678 ▲15922.19 ▼1.18583.55 ▼68.9345.17 ▼23.33
Media Library /wp-admin/upload.php1,399 ▲114.22 ▲0.0797.57 ▲4.1173.83 ▲32.82

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
  • This plugin does not fully uninstall, leaving 6 options in the database
    • widget_theysaidso_widget
    • widget_recent-posts
    • widget_recent-comments
    • db_upgraded
    • theysaidso_admin_options
    • can_compress_scripts

Smoke tests Passed 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 Passed 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
Congratulations! This plugin passed the SRP test

User-side errors Passed 1 test

🔹 Test weight: 20 | This is a smoke test targeting browser errors/issues
Everything seems fine, but this is not an exhaustive test

Optimizations

Plugin configuration 90% from 29 tests

readme.txt 88% from 16 tests

The readme.txt file uses markdown syntax to describe your plugin to the world
Attributes that need to be fixed:
  • Screenshots: Please a description for screenshot #1 in ninja-toastify/assets to your readme.txt
  • Tags: Please reduce the number of tags, currently 11 tag instead of maximum 10
You can take inspiration from this readme.txt

ninja-toastify/ninja-toastify.php 92% from 13 tests

The entry point to "Ninja Toastify" version 1.0.1 is a PHP file that has certain tags in its header comment area
Please make the necessary changes and fix the following:
  • Description: If Twitter did it, so should we! Keep the description under 140 characters (currently 156 characters long)

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
No dangerous file extensions were detected4,618 lines of code in 15 files:
LanguageFilesBlank linesComment linesLines of code
JavaScript41,0061,2574,261
JSX134168
PHP62564142
Sass13041
CSS30146

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.09
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 50% from 2 tests

Image compression 50% from 2 tests

PNG files should be compressed to save space and minimize bandwidth usage
3 PNG files occupy 2.31MB with 0.96MB in potential savings
Potential savings
Compression of 3 random PNG files using pngquant
FileSize - originalSize - compressedSavings
assets/banner-772x250.png877.01KB351.56KB▼ 59.91%
assets/logo-min.png0.39KB0.34KB▼ 13.40%
assets/screenshot-1.png1,485.41KB719.45KB▼ 51.57%