79% get-user-custom-field-values

Code Review | Get User Custom Field Values

WordPress plugin Get User Custom Field Values scored79%from 54 tests.

About plugin

  • Plugin page: get-user-custom-f...
  • Plugin version: 3.3
  • PHP version: 7.4.16
  • WordPress compatibility: 4.6-5.8
  • WordPress version: 6.3.1
  • First release: Aug 8, 2011
  • Latest release: Nov 21, 2021
  • Number of updates: 18
  • Update frequency: every 253.3 days
  • Top authors: coffee2code (100%)

Code review

54 tests

User reviews

3 reviews

Install metrics

200+ active /12,232 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
The plugin installed successfully, without throwing any errors or notices

Server metrics [RAM: ▲0.08MB] [CPU: ▼11.33ms] Passed 4 tests

An overview of server-side resources used by Get User Custom Field Values
Normal server usage
PageMemory (MB)CPU Time (ms)
Home /3.56 ▲0.1038.07 ▼3.53
Dashboard /wp-admin3.39 ▲0.0446.80 ▼18.58
Posts /wp-admin/edit.php3.50 ▲0.1548.86 ▼6.87
Add New Post /wp-admin/post-new.php5.97 ▲0.0981.78 ▼16.34
Media Library /wp-admin/upload.php3.31 ▲0.0835.40 ▼1.26

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

A short overview of filesystem and database impact
The plugin installed successfully
Filesystem: 17 new files
Database: no new tables, 7 new options
New WordPress options
widget_get-user-custom
db_upgraded
can_compress_scripts
widget_recent-comments
theysaidso_admin_options
widget_theysaidso_widget
widget_recent-posts

Browser metrics Passed 4 tests

Checking browser requirements for Get User Custom Field Values
Minimal impact on browser resources
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,789 ▲2814.24 ▲0.231.72 ▼0.0439.63 ▼2.47
Dashboard /wp-admin2,195 ▲245.54 ▼0.0892.09 ▲3.2436.62 ▼2.80
Posts /wp-admin/edit.php2,100 ▼02.02 ▼0.0138.98 ▲1.5936.51 ▼1.06
Add New Post /wp-admin/post-new.php1,534 ▲618.16 ▼5.09626.81 ▼54.0868.92 ▲12.23
Media Library /wp-admin/upload.php1,400 ▼04.18 ▼0.01100.32 ▼5.7744.10 ▼2.48

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
These items require your attention
  • This plugin did not uninstall successfully, leaving 7 options in the database
    • widget_get-user-custom
    • widget_theysaidso_widget
    • widget_recent-comments
    • theysaidso_admin_options
    • can_compress_scripts
    • db_upgraded
    • widget_recent-posts

Smoke tests 50% from 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | A shallow check that no server-side errors were triggered
Good news, no errors were detected

SRP 0% 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
Please fix the following
  • 1× PHP files perform the task of outputting text when accessed with GET requests:
    • > /wp-content/plugins/get-user-custom-field-values/tests/phpunit/bootstrap.php
  • 2× PHP files trigger server errors when accessed directly:
    • > PHP Fatal error
      require_once(): Failed opening required '/tmp/wordpress-tests-lib/tests/phpunit/includes/functions.php' (include_path='.:/usr/share/php') in wp-content/plugins/get-user-custom-field-values/tests/phpunit/bootstrap.php on line 29
    • > PHP Warning
      require_once(/tmp/wordpress-tests-lib/tests/phpunit/includes/functions.php): failed to open stream: No such file or directory in wp-content/plugins/get-user-custom-field-values/tests/phpunit/bootstrap.php on line 29

User-side errors Passed 1 test

🔹 Test weight: 20 | This is a smoke test targeting browser errors/issues
No browser errors were detected

Optimizations

Plugin configuration Passed 29 tests

readme.txt Passed 16 tests

The readme.txt file is undoubtedly the most important file in your plugin, preparing it for public listing on WordPress.org
6 plugin tags: widget, shortcode, custom field, coffee2code, user meta...

get-user-custom-field-values/get-user-custom-field-values.php Passed 13 tests

"Get User Custom Field Values" version 3.3's main PHP file describes plugin functionality and also serves as the entry point to any WordPress functionality
107 characters long description:
Use widgets, shortcodes, and/or template tags to easily retrieve and display custom field values for users.

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
Everything looks great! No dangerous files found in this plugin1,702 lines of code in 15 files:
LanguageFilesBlank linesComment linesLines of code
PHP94014871,235
Markdown41340432
Bourne Shell16221
XML10014

PHP code Passed 2 tests

A short review of cyclomatic complexity and code structure
There were no cyclomatic complexity issued detected
Cyclomatic complexity
Average complexity per logical line of code0.23
Average class complexity16.83
▷ Minimum class complexity5.00
▷ Maximum class complexity41.00
Average method complexity1.81
▷ Minimum method complexity1.00
▷ Maximum method complexity31.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes6
▷ Abstract classes116.67%
▷ Concrete classes583.33%
▷ Final classes00.00%
Methods122
▷ Static methods54.10%
▷ Public methods11190.98%
▷ Protected methods00.00%
▷ Private methods119.02%
Functions11
▷ Named functions436.36%
▷ Anonymous functions763.64%
Constants1
▷ Global constants1100.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
There were not PNG files found in your plugin