72% custom-field-list-widget

Code Review | Custom Field List Widget

WordPress plugin Custom Field List Widget scored72%from 54 tests.

About plugin

  • Plugin page: custom-field-list...
  • Plugin version: 1.5.1
  • PHP version: 7.4.16
  • WordPress compatibility: 2.7-5.8
  • WordPress version: 6.3.1
  • First release: Mar 18, 2009
  • Latest release: Apr 10, 2021
  • Number of updates: 220
  • Update frequency: every 20.0 days
  • Top authors: ntm (100%)

Code review

54 tests

User reviews

2 reviews

Install metrics

100+ active /24,881 total downloads

Benchmarks

Plugin footprint 83% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | Checking the installer triggered no errors
Install script ran successfully

Server metrics [RAM: ▲0.41MB] [CPU: ▲5.00ms] Passed 4 tests

A check of server-side resources used by Custom Field List Widget
Normal server usage
PageMemory (MB)CPU Time (ms)
Home /3.87 ▲0.4142.93 ▲5.91
Dashboard /wp-admin3.71 ▲0.4149.64 ▲3.92
Posts /wp-admin/edit.php3.82 ▲0.4751.51 ▲4.55
Add New Post /wp-admin/post-new.php6.29 ▲0.4195.98 ▲5.60
Media Library /wp-admin/upload.php3.63 ▲0.4038.66 ▲6.63
Custom Field List /wp-admin/options-general.php?page=custom-field-list-widget/widget_custom_field_list.php3.5732.73

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

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

Browser metrics Passed 4 tests

Custom Field List Widget: an overview of browser usage
This plugin renders optimally with no browser resource issues detected
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,895 ▲16013.96 ▼0.795.54 ▲3.7638.29 ▼5.74
Dashboard /wp-admin2,210 ▲184.85 ▼0.04108.86 ▼0.6539.48 ▼5.02
Posts /wp-admin/edit.php2,093 ▲12.03 ▲0.0436.21 ▼1.6636.10 ▼1.12
Add New Post /wp-admin/post-new.php1,539 ▲1923.23 ▲0.01618.23 ▼58.8762.13 ▲8.41
Media Library /wp-admin/upload.php1,395 ▲134.22 ▲0.0594.71 ▼4.1039.88 ▼2.24
Custom Field List /wp-admin/options-general.php?page=custom-field-list-widget/widget_custom_field_list.php8462.0526.2725.81

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

🔸 Tests weight: 35 | All plugins must uninstall correctly, removing their source code and extra database tables they might have created
These items require your attention
  • Zombie WordPress options were found after uninstall: 6 options
    • widget_recent-posts
    • widget_recent-comments
    • widget_theysaidso_widget
    • can_compress_scripts
    • db_upgraded
    • theysaidso_admin_options

Smoke tests 25% from 4 tests

Server-side errors 0% from 1 test

🔹 Test weight: 20 | A smoke test targeting server-side errors
Please fix the following server-side errors
  • 8 occurences, only the last one shown
    • > GET request to /wp-admin/options-general.php?page=custom-field-list-widget/widget_custom_field_list.php
    • > Notice in wp-content/plugins/custom-field-list-widget/widget_custom_field_list.php+2502
    Trying to access array offset on value of type bool

SRP 0% from 2 tests

🔹 Tests weight: 20 | The single-responsibility principle applies for WordPress plugins as well - please make sure your PHP files perform no actions when accessed directly
Please fix the following
  • 6× PHP files perform the task of outputting text when accessed with GET requests:
    • > /wp-content/plugins/custom-field-list-widget/widget_custom_field_list_long_selectbox.php
    • > /wp-content/plugins/custom-field-list-widget/widget_custom_field_list_individual_href.php
    • > /wp-content/plugins/custom-field-list-widget/widget_custom_field_list_individual_href_advice.php
    • > /wp-content/plugins/custom-field-list-widget/widget_custom_field_list_individual_href_save_data.php
    • > /wp-content/plugins/custom-field-list-widget/uninstall.php
    • > /wp-content/plugins/custom-field-list-widget/widget_custom_field_list_js.php
  • 1× GET requests to PHP files trigger server-side errors or Error 500 responses:
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_action() in wp-content/plugins/custom-field-list-widget/widget_custom_field_list.php:54

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 90% from 29 tests

readme.txt 94% from 16 tests

The readme.txt file uses markdown syntax to describe your plugin to the world
These attributes need to be fixed:
  • Donate link: Please fix this invalid URI: ""
You can look at the official readme.txt

custom-field-list-widget/widget_custom_field_list.php 85% from 13 tests

Analyzing the main PHP file in "Custom Field List Widget" version 1.5.1
You should first fix the following items:
  • Description: Keep the plugin description shorter than 140 characters (currently 145 characters long)
  • Main file name: The principal plugin file should be the same as the plugin slug ("custom-field-list-widget.php" instead of "widget_custom_field_list.php")

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | Executable files are considered dangerous and should not be included with any WordPress plugin
No dangerous file extensions were detected5,090 lines of code in 17 files:
LanguageFilesBlank linesComment linesLines of code
PHP82342782,544
PO File78741,2202,339
CSS2726207

PHP code Passed 2 tests

An short overview of logical lines of code, cyclomatic complexity, and other code metrics
No cyclomatic complexity issues were detected for this plugin
Cyclomatic complexity
Average complexity per logical line of code0.48
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%
Functions25
▷ Named functions25100.00%
▷ Anonymous functions00.00%
Constants7
▷ Global constants7100.00%
▷ Class constants00.00%
▷ Public constants00.00%

Plugin size Passed 2 tests

Image compression Passed 2 tests

It is recommended to compress PNG files in your plugin to minimize bandwidth usage
2 PNG files occupy 0.03MB with 0.02MB in potential savings
Potential savings
Compression of 2 random PNG files using pngquant
FileSize - originalSize - compressedSavings
assets/icon-128x128.png8.92KB3.91KB▼ 56.16%
assets/icon-256x256.png20.53KB7.29KB▼ 64.46%