84% txtoit-icons-for-plugins

Code Review | Icons for Plugins - TxToIT

WordPress plugin Icons for Plugins - TxToIT scored84%from 54 tests.

About plugin

  • Plugin page: txtoit-icons-for-...
  • Plugin version: 1.0.6
  • PHP compatiblity: 5.4+
  • PHP version: 7.4.16
  • WordPress compatibility: 4.4-4.9
  • WordPress version: 6.3.1
  • First release: Nov 26, 2017
  • Latest release: Mar 22, 2018
  • Number of updates: 40
  • Update frequency: every 2.9 days
  • Top authors: Karzin (100%)

Code review

54 tests

User reviews

1 review

Install metrics

10+ active /828 total downloads

Benchmarks

Plugin footprint 83% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | Verifying that this plugin installs correctly without errors
This plugin's installer ran successfully

Server metrics [RAM: ▲0.24MB] [CPU: ▼1.21ms] Passed 4 tests

This is a short check of server-side resources used by Icons for Plugins - TxToIT
Server-side resource usage in normal parameters
PageMemory (MB)CPU Time (ms)
Home /3.58 ▲0.1239.24 ▼2.65
Dashboard /wp-admin3.64 ▲0.3450.58 ▲1.51
Posts /wp-admin/edit.php3.69 ▲0.3354.98 ▲4.85
Add New Post /wp-admin/post-new.php6.13 ▲0.2587.27 ▼3.72
Media Library /wp-admin/upload.php3.47 ▲0.2537.62 ▲0.04
Plugins icons /wp-admin/options-general.php?page=txtoit-icons-for-plugins3.4737.72

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

Analyzing filesystem and database footprints of this plugin
The plugin installed successfully
Filesystem: 149 new files
Database: no new tables, 7 new options
New WordPress options
theysaidso_admin_options
widget_theysaidso_widget
db_upgraded
can_compress_scripts
widget_recent-comments
widget_recent-posts
ifp_general

Browser metrics Passed 4 tests

A check of browser resources used by Icons for Plugins - TxToIT
Normal browser usage
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,958 ▲20115.23 ▲0.871.71 ▼0.3838.73 ▼7.97
Dashboard /wp-admin2,367 ▲1826.64 ▲1.71132.88 ▲27.0741.55 ▼1.69
Posts /wp-admin/edit.php2,276 ▲1873.60 ▲1.5455.95 ▲15.6035.57 ▲0.92
Add New Post /wp-admin/post-new.php1,529 ▲123.59 ▲5.27609.17 ▼14.5334.88 ▼19.03
Media Library /wp-admin/upload.php1,400 ▲154.32 ▲0.0581.76 ▼14.9142.52 ▲0.65
Plugins icons /wp-admin/options-general.php?page=txtoit-icons-for-plugins1,1333.4146.6126.39

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

🔸 Tests weight: 35 | All plugins must uninstall correctly, removing their source code and extra database tables they might have created
You still need to fix the following
  • Zombie WordPress options detected upon uninstall: 7 options
    • widget_recent-posts
    • can_compress_scripts
    • db_upgraded
    • widget_theysaidso_widget
    • widget_recent-comments
    • theysaidso_admin_options
    • ifp_general

Smoke tests 75% from 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | A smoke test targeting server-side errors
Good news, no errors were detected

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
  • 103× GET requests to PHP files trigger server-side errors or Error 500 responses (only 10 are shown):
    • > PHP Fatal error
      Uncaught Error: Class 'Composer\\Installers\\BaseInstaller' not found in wp-content/plugins/txtoit-icons-for-plugins/vendor/composer/installers/src/Composer/Installers/ChefInstaller.php:4
    • > PHP Fatal error
      Uncaught Error: Class 'Composer\\Installers\\BaseInstaller' not found in wp-content/plugins/txtoit-icons-for-plugins/vendor/composer/installers/src/Composer/Installers/CodeIgniterInstaller.php:4
    • > PHP Fatal error
      Uncaught Error: Class 'Composer\\Installers\\Test\\TestCase' not found in wp-content/plugins/txtoit-icons-for-plugins/vendor/composer/installers/tests/Composer/Installers/Test/GravInstallerTest.php:7
    • > PHP Fatal error
      Uncaught Error: Class 'Composer\\Installers\\BaseInstaller' not found in wp-content/plugins/txtoit-icons-for-plugins/vendor/composer/installers/src/Composer/Installers/RedaxoInstaller.php:4
    • > PHP Fatal error
      Uncaught Error: Class 'Composer\\Installers\\BaseInstaller' not found in wp-content/plugins/txtoit-icons-for-plugins/vendor/composer/installers/src/Composer/Installers/PuppetInstaller.php:5
    • > PHP Fatal error
      Uncaught Error: Class 'Composer\\Installers\\BaseInstaller' not found in wp-content/plugins/txtoit-icons-for-plugins/vendor/composer/installers/src/Composer/Installers/ImageCMSInstaller.php:4
    • > PHP Fatal error
      Uncaught Error: Class 'Composer\\Installers\\BaseInstaller' not found in wp-content/plugins/txtoit-icons-for-plugins/vendor/composer/installers/src/Composer/Installers/MediaWikiInstaller.php:4
    • > PHP Fatal error
      Uncaught Error: Class 'Composer\\Installers\\BaseInstaller' not found in wp-content/plugins/txtoit-icons-for-plugins/vendor/composer/installers/src/Composer/Installers/YawikInstaller.php:12
    • > PHP Fatal error
      Uncaught Error: Class 'Composer\\Installers\\BaseInstaller' not found in wp-content/plugins/txtoit-icons-for-plugins/vendor/composer/installers/src/Composer/Installers/MauticInstaller.php:4
    • > PHP Fatal error
      Uncaught Error: Class 'Composer\\Installers\\Test\\TestCase' not found in wp-content/plugins/txtoit-icons-for-plugins/vendor/composer/installers/tests/Composer/Installers/Test/YawikInstallerTest.php:14

User-side errors Passed 1 test

🔹 Test weight: 20 | This is a smoke test targeting browser errors/issues
Everything seems fine on the user side

Optimizations

Plugin configuration Passed 29 tests

readme.txt Passed 16 tests

You should put a lot of thought into formatting readme.txt as it is used by WordPress.org to prepare the public listing of your plugin
7 plugin tags: list, dashboard, admin, plugins, page...

txtoit-icons-for-plugins/txtoit-icons-for-plugins.php Passed 13 tests

The main PHP script in "Icons for Plugins - TxToIT" version 1.0.6 is automatically included on every request by WordPress
36 characters long description:
Displays icons for WordPress plugins

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
Good job! No executable or dangerous file extensions detected5,292 lines of code in 136 files:
LanguageFilesBlank linesComment linesLines of code
PHP1227861,2754,468
Markdown5970400
JSON500367
XML23031
YAML27026

PHP code Passed 2 tests

An overview of cyclomatic complexity and code structure
Although this was not an exhaustive test, there were no cyclomatic complexity issues detected
Cyclomatic complexity
Average complexity per logical line of code0.23
Average class complexity3.12
▷ Minimum class complexity1.00
▷ Maximum class complexity69.00
Average method complexity2.02
▷ Minimum method complexity1.00
▷ Maximum method complexity22.00
Code structure
Namespaces5
Interfaces0
Traits0
Classes114
▷ Abstract classes21.75%
▷ Concrete classes11298.25%
▷ Final classes00.00%
Methods241
▷ Static methods3112.86%
▷ Public methods19380.08%
▷ Protected methods3614.94%
▷ Private methods124.98%
Functions7
▷ Named functions228.57%
▷ Anonymous functions571.43%
Constants3
▷ Global constants00.00%
▷ Class constants3100.00%
▷ Public constants3100.00%

Plugin size Passed 2 tests

Image compression Passed 2 tests

Often times overlooked, PNG files can occupy unnecessary space in your plugin
1 PNG file occupies 0.38MB with 0.27MB in potential savings
Potential savings
Compression of 1 random PNG file using pngquant
FileSize - originalSize - compressedSavings
vendor/tareq1988/wordpress-settings-api-class/screenshot-1.png389.59KB115.93KB▼ 70.24%