90% category-icon

Code Review | Category Icon

WordPress plugin Category Icon scored90%from 54 tests.

About plugin

  • Plugin page: category-icon
  • Plugin version: 1.0.0
  • PHP compatiblity: 5.6.40+
  • PHP version: 7.4.16
  • WordPress compatibility: 4.9.19-5.9.0
  • WordPress version: 6.3.1
  • First release: Oct 10, 2015
  • Latest release: Jan 31, 2022
  • Number of updates: 13
  • Update frequency: every 177.5 days
  • Top authors: euthelup (53.85%)pixelgrade (30.77%)babbardel (30.77%)

Code review

54 tests

User reviews

3 reviews

Install metrics

3,000+ active /79,352 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
Installer ran successfully

Server metrics [RAM: ▲0.14MB] [CPU: ▼6.77ms] Passed 4 tests

This is a short check of server-side resources used by Category Icon
This plugin has minimal impact on server resources
PageMemory (MB)CPU Time (ms)
Home /3.50 ▲0.0435.22 ▼7.82
Dashboard /wp-admin3.49 ▲0.1946.99 ▼5.10
Posts /wp-admin/edit.php3.57 ▲0.2154.82 ▲7.59
Add New Post /wp-admin/post-new.php6.11 ▲0.2281.80 ▼13.04
Media Library /wp-admin/upload.php3.35 ▲0.1234.71 ▼1.12
Category Icon /wp-admin/options-general.php?page=category-icon3.3533.11

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

Input-output and database impact of this plugin
The plugin installed successfully
Filesystem: 6 new files
Database: no new tables, 7 new options
New WordPress options
widget_recent-comments
widget_theysaidso_widget
category-icon
theysaidso_admin_options
db_upgraded
widget_recent-posts
can_compress_scripts

Browser metrics Passed 4 tests

This is an overview of browser requirements for Category Icon
Normal browser usage
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,950 ▲21514.96 ▲0.581.55 ▼0.2040.37 ▼2.81
Dashboard /wp-admin2,356 ▲1716.46 ▲0.57117.70 ▼0.2939.56 ▼5.68
Posts /wp-admin/edit.php2,265 ▲1763.31 ▲1.3554.96 ▲17.4334.91 ▲0.12
Add New Post /wp-admin/post-new.php1,541 ▲2022.84 ▼0.36561.09 ▼133.0834.44 ▼22.32
Media Library /wp-admin/upload.php1,395 ▲74.21 ▼0.0783.78 ▼28.2242.07 ▼5.88
Category Icon /wp-admin/options-general.php?page=category-icon1,0393.0939.4324.50

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

🔸 Tests weight: 35 | It is important to correctly uninstall your plugin, without leaving any traces
It is recommended to fix the following
  • Zombie WordPress options were found after uninstall: 7 options
    • widget_theysaidso_widget
    • category-icon
    • widget_recent-comments
    • widget_recent-posts
    • theysaidso_admin_options
    • can_compress_scripts
    • db_upgraded

Smoke tests Passed 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | This is a shallow check for server-side errors
The smoke test was a success, however most plugin functionality was not tested

SRP Passed 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
Looking good! No server-side errors or output on direct access of PHP files

User-side errors Passed 1 test

🔹 Test weight: 20 | A shallow check that no browser errors were triggered
Everything seems fine on the user side

Optimizations

Plugin configuration 96% from 29 tests

readme.txt Passed 16 tests

Perhaps the most important file in your plugin readme.txt gets parsed in order to generate the public listing of your plugin
5 plugin tags: category, term, taxonomy, image, icon

category-icon/category-icon.php 92% from 13 tests

This is the main PHP file of "Category Icon" version 1.0.0, providing information about the plugin in the header fields and serving as the principal entry point to the plugin's functions
The following require your attention:
  • Domain Path: The domain path folder was not found ("/lang")

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | A short check of programming languages and file extensions; no executable files are allowed
Everything looks great! No dangerous files found in this plugin674 lines of code in 4 files:
LanguageFilesBlank linesComment linesLines of code
PHP295102395
JavaScript16446206
CSS110073

PHP code Passed 2 tests

This is a short overview of cyclomatic complexity and code structure for this plugin
Although this was not an exhaustive test, there were no cyclomatic complexity issues detected
Cyclomatic complexity
Average complexity per logical line of code0.32
Average class complexity36.00
▷ Minimum class complexity36.00
▷ Maximum class complexity36.00
Average method complexity2.40
▷ Minimum method complexity1.00
▷ Maximum method complexity8.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes1
▷ Abstract classes00.00%
▷ Concrete classes1100.00%
▷ Final classes00.00%
Methods25
▷ Static methods14.00%
▷ Public methods2496.00%
▷ Protected methods14.00%
▷ Private methods00.00%
Functions4
▷ Named functions4100.00%
▷ Anonymous functions00.00%
Constants0
▷ Global constants00.00%
▷ Class constants00.00%
▷ Public constants00.00%

Plugin size Passed 2 tests

Image compression Passed 2 tests

Using a strong compression for your PNG files is a great way to speed-up your plugin
There are no PNG files in this plugin