83% item-list

Code Review | Item List

WordPress plugin Item List scored 83% from 54 tests.

About plugin

  • Plugin page: item-list
  • Plugin version: 1.0.0
  • PHP version: 7.4.16
  • WordPress compatibility: 5.1-5.8
  • WordPress version: 6.3.1
  • First release: Sep 14, 2021
  • Latest release: Sep 14, 2021
  • Number of updates: 10
  • Update frequency: N/A
  • Top authors: zworthkey (100%)

Code review

54 tests

User reviews

1 review

Install metrics

10+ active / 321 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.06MB] [CPU: ▼3.36ms] Passed 4 tests

Server-side resources used by Item List
This plugin has minimal impact on server resources
PageMemory (MB)CPU Time (ms)
Home /3.52 ▲0.0633.65 ▼8.08
Dashboard /wp-admin3.36 ▲0.0545.89 ▼5.58
Posts /wp-admin/edit.php3.47 ▲0.1149.94 ▲0.34
Add New Post /wp-admin/post-new.php5.96 ▲0.0794.91 ▼0.12
Media Library /wp-admin/upload.php3.28 ▲0.0543.66 ▲7.81

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

How much does this plugin use your filesystem and database?
This plugin installed successfully
Filesystem: 22 new files
Database: no new tables, 6 new options
New WordPress options
widget_theysaidso_widget
db_upgraded
widget_recent-comments
can_compress_scripts
widget_recent-posts
theysaidso_admin_options

Browser metrics Passed 4 tests

Checking browser requirements for Item List
Normal browser usage
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,887 ▲15213.58 ▼0.837.71 ▲5.6141.43 ▼11.57
Dashboard /wp-admin2,213 ▲224.84 ▼1.06107.44 ▲5.2341.59 ▼5.44
Posts /wp-admin/edit.php2,096 ▲72.00 ▼0.0539.36 ▲2.8934.44 ▼0.38
Add New Post /wp-admin/post-new.php1,520 ▼1523.02 ▼0.10631.05 ▼49.2363.22 ▼1.76
Media Library /wp-admin/upload.php1,392 ▲44.25 ▲0.0591.95 ▼17.8341.49 ▼5.76

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

🔸 Tests weight: 35 | The uninstall procedure must remove all plugin files and extra database tables
These items require your attention
  • This plugin did not uninstall successfully, leaving 6 options in the database
    • widget_recent-posts
    • widget_theysaidso_widget
    • widget_recent-comments
    • theysaidso_admin_options
    • db_upgraded
    • can_compress_scripts

Smoke tests 75% from 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | This is a short smoke test looking for server-side errors
Even though everything seems fine, this is not an exhaustive test

SRP 50% from 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
The following issues need your attention
  • 2× GET requests to PHP files return non-empty strings:
    • > /wp-content/plugins/item-list/admin/partials/zwk-item-list-admin-display.php
    • > /wp-content/plugins/item-list/public/partials/zwk-item-list-public-display.php

User-side errors Passed 1 test

🔹 Test weight: 20 | This is a shallow check for browser errors
There were no browser issues found

Optimizations

Plugin configuration 87% from 29 tests

readme.txt 88% from 16 tests

The readme.txt file is undoubtedly the most important file in your plugin, preparing it for public listing on WordPress.org
These attributes need to be fixed:
  • Plugin Name: "Plugin Name" should be replaced with the name of your plugin on the first line ( === item-list === )
  • Donate link: Invalid url: ""
You can take inspiration from this readme.txt

item-list/zwk-item-list.php 85% from 13 tests

The main PHP script in "Item List" version 1.0.0 is automatically included on every request by WordPress
It is important to fix the following:
  • Text Domain: You no longer need to specify the text domain since WordPress 4.6; it must be the same as the plugin slug
  • Main file name: Name the main plugin file the same as the plugin slug ("item-list.php" instead of "zwk-item-list.php")

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
Good job! No executable or dangerous file extensions detected203 lines of code in 16 files:
LanguageFilesBlank linesComment linesLines of code
PHP12123535197
JavaScript24546
CSS2080

PHP code Passed 2 tests

Cyclomatic complexity and code structure are the fingerprint of this plugin
No cyclomatic complexity issues were detected for this plugin
Cyclomatic complexity
Average complexity per logical line of code0.13
Average class complexity2.14
▷ Minimum class complexity1.00
▷ Maximum class complexity6.00
Average method complexity1.32
▷ Minimum method complexity1.00
▷ Maximum method complexity4.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes7
▷ Abstract classes00.00%
▷ Concrete classes7100.00%
▷ Final classes00.00%
Methods25
▷ Static methods28.00%
▷ Public methods2080.00%
▷ Protected methods00.00%
▷ Private methods520.00%
Functions3
▷ Named functions3100.00%
▷ Anonymous functions00.00%
Constants1
▷ Global constants1100.00%
▷ Class constants00.00%
▷ Public constants00.00%

Plugin size Passed 2 tests

Image compression Passed 2 tests

Often times overlooked, PNG files can occupy unnecessary space in your plugin
No PNG files were detected