84% za-my-favorite-plugins-installer

Code Review | ZA My Favorite Plugins Installer

WordPress plugin ZA My Favorite Plugins Installer scored84%from 54 tests.

About plugin

  • Plugin page: za-my-favorite-pl...
  • Plugin version: 1.0
  • PHP version: 7.4.16
  • WordPress compatibility: 4.0-4.1
  • WordPress version: 6.3.1
  • First release: Mar 12, 2015
  • Latest release: Mar 12, 2015
  • Number of updates: 5
  • Update frequency: every 0.2 days
  • Top authors: zeeshanarshad (100%)

Code review

54 tests

User reviews

1 review

Install metrics

10+ active /1,021 total downloads

Benchmarks

Plugin footprint 83% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | Checking the installer triggered no errors
The plugin installed gracefully, with no errors

Server metrics [RAM: ▼0.00MB] [CPU: ▼6.09ms] Passed 4 tests

Analyzing server-side resources used by ZA My Favorite Plugins Installer
Server-side resource usage in normal parameters
PageMemory (MB)CPU Time (ms)
Home /3.47 ▲0.0039.52 ▲0.12
Dashboard /wp-admin3.31 ▼0.0342.69 ▼19.12
Posts /wp-admin/edit.php3.36 ▲0.0145.21 ▼1.17
Add New Post /wp-admin/post-new.php5.89 ▲0.0183.55 ▲0.96
Media Library /wp-admin/upload.php3.24 ▲0.0133.48 ▼4.19

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

A short overview of filesystem and database impact
No storage issues were detected
Filesystem: 6 new files
Database: no new tables, 6 new options
New WordPress options
theysaidso_admin_options
db_upgraded
widget_recent-comments
can_compress_scripts
widget_recent-posts
widget_theysaidso_widget

Browser metrics Passed 4 tests

A check of browser resources used by ZA My Favorite Plugins Installer
There were no issues detected in relation to browser resource usage
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,800 ▲5414.24 ▼0.111.76 ▲0.1343.91 ▲1.87
Dashboard /wp-admin2,206 ▲255.52 ▼0.2184.26 ▼17.5074.58 ▲30.34
Posts /wp-admin/edit.php2,114 ▲141.99 ▲0.0438.46 ▲3.7234.37 ▲0.61
Add New Post /wp-admin/post-new.php1,564 ▲3818.44 ▼2.61620.88 ▼14.11159.40 ▲100.97
Media Library /wp-admin/upload.php1,411 ▲84.13 ▼0.0895.87 ▼6.8267.27 ▲24.28

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

🔸 Tests weight: 35 | Checking the uninstaller removed all traces of the plugin
These items require your attention
  • This plugin does not fully uninstall, leaving 6 options in the database
    • widget_recent-comments
    • theysaidso_admin_options
    • widget_theysaidso_widget
    • can_compress_scripts
    • db_upgraded
    • widget_recent-posts

Smoke tests 75% from 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | A shallow check that no server-side errors were triggered
Even though no errors were found, this is by no means an exhaustive test

SRP 50% from 2 tests

🔹 Tests weight: 20 | It is important to ensure that your PHP files perform no action when accessed directly, respecting the single-responsibility principle
The following issues need your attention
  • 2× GET requests to PHP files have triggered server-side errors or warnings:
    • > PHP Fatal error
      Uncaught Error: Call to undefined function current_user_can() in wp-content/plugins/za-my-favorite-plugins-installer/plugin_installer.php:3
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_action() in wp-content/plugins/za-my-favorite-plugins-installer/za-favorite-plugins-installer.php:29

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)
Everything seems fine on the user side

Optimizations

Plugin configuration 96% from 29 tests

readme.txt Passed 16 tests

Often overlooked, readme.txt is one of the most important files in your plugin
7 plugin tags: installer, plugins, automatic, auto, custom...

za-my-favorite-plugins-installer/za-favorite-plugins-installer.php 92% from 13 tests

"ZA My Favorite Plugins Installer" version 1.0's main PHP file describes plugin functionality and also serves as the entry point to any WordPress functionality
It is important to fix the following:
  • Main file name: Name the main plugin file the same as the plugin slug ("za-my-favorite-plugins-installer.php" instead of "za-favorite-plugins-installer.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
No dangerous file extensions were detected204 lines of code in 2 files:
LanguageFilesBlank linesComment linesLines of code
PHP25558204

PHP code Passed 2 tests

Analyzing logical lines of code, cyclomatic complexity, and other code metrics
This plugin has no cyclomatic complexity issues
Cyclomatic complexity
Average complexity per logical line of code0.26
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%
Functions5
▷ Named functions5100.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
2 PNG files occupy 0.05MB with 0.04MB in potential savings
Potential savings
Compression of 2 random PNG files using pngquant
FileSize - originalSize - compressedSavings
images/tick.png2.58KB1.79KB▼ 30.72%
images/logo.png53.67KB1.10KB▼ 97.96%