74% author-profile-widget

Code Review | Author Profile Widget

WordPress plugin Author Profile Widget scored74%from 54 tests.

About plugin

  • Plugin page: author-profile-wi...
  • Plugin version: 0.4.2
  • PHP version: 7.4.16
  • WordPress compatibility: 3.9.1-4.1.0
  • WordPress version: 6.3.1
  • First release: Jul 4, 2014
  • Latest release: Dec 25, 2014
  • Number of updates: 9
  • Update frequency: every 19.6 days
  • Top authors: inc2734 (100%)

Code review

54 tests

User reviews

1 review

Install metrics

100+ active /3,205 total downloads

Benchmarks

Plugin footprint 65% 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: ▼1.65MB] [CPU: ▼53.92ms] Passed 4 tests

Analyzing server-side resources used by Author Profile Widget
No issues were detected with server-side resource usage
PageMemory (MB)CPU Time (ms)
Home /2.35 ▼1.119.99 ▼28.66
Dashboard /wp-admin2.37 ▼0.9813.00 ▼50.26
Posts /wp-admin/edit.php2.37 ▼0.9911.54 ▼43.92
Add New Post /wp-admin/post-new.php2.37 ▼3.5212.11 ▼92.84
Media Library /wp-admin/upload.php2.37 ▼0.8611.05 ▼25.45

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

Input-output and database impact of this plugin
There were no storage issued detected upon installing this plugin
Filesystem: 11 new files
Database: no new tables, 8 new options
New WordPress options
widget_theysaidso_widget
widget_recent-posts
db_upgraded
can_compress_scripts
widget_author-profile-widget-profile
widget_recent-comments
widget_author-profile-widget-list
theysaidso_admin_options

Browser metrics Passed 4 tests

Checking browser requirements for Author Profile Widget
There were no issues detected in relation to browser resource usage
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,791 ▲514.27 ▼0.111.96 ▼0.1546.96 ▲1.73
Dashboard /wp-admin2,192 ▲155.61 ▼0.0297.44 ▲7.5543.52 ▲1.66
Posts /wp-admin/edit.php2,097 ▼32.01 ▲0.0738.09 ▼2.7335.03 ▼4.59
Add New Post /wp-admin/post-new.php1,526 ▼223.59 ▲0.42669.11 ▼23.0751.15 ▼9.99
Media Library /wp-admin/upload.php1,400 ▼04.22 ▲0.0298.13 ▼17.8343.62 ▼4.82

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

🔸 Tests weight: 35 | Verifying that this plugin uninstalls completely without leaving any traces
You still need to fix the following
  • Uninstall procedure validation failed for this plugin
    • > User deprecated in wp-includes/functions.php+5546
    The called constructor method for WP_Widget class in Author_Profile_Widget_Profile is deprecated since version 4.3.0! Use __construct() instead.
  • Zombie WordPress options detected upon uninstall: 8 options
    • can_compress_scripts
    • widget_author-profile-widget-profile
    • widget_author-profile-widget-list
    • widget_theysaidso_widget
    • widget_recent-posts
    • db_upgraded
    • theysaidso_admin_options
    • widget_recent-comments

Smoke tests 75% from 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | Just a short smoke test targeting errors on the server (in the Apache logs)
Even though everything seems fine, this is not an exhaustive test

SRP 50% from 2 tests

🔹 Tests weight: 20 | SRP (Single-Responsibility Principle) - PHP files must act as libraries and never output text or perform any action when accessed directly in a browser
Please fix the following
  • 4× 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/author-profile-widget/author-profile-widget.php:26
    • > PHP Fatal error
      Uncaught Error: Class 'Author_Profile_Widget_Base' not found in wp-content/plugins/author-profile-widget/system/list.php:11
    • > PHP Fatal error
      Uncaught Error: Class 'WP_Widget' not found in wp-content/plugins/author-profile-widget/system/widget.php:11
    • > PHP Fatal error
      Uncaught Error: Class 'Author_Profile_Widget_Base' not found in wp-content/plugins/author-profile-widget/system/profile.php:11

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

readme.txt 94% from 16 tests

The readme.txt file is undoubtedly the most important file in your plugin, preparing it for public listing on WordPress.org
Attributes that require attention: You can look at the official readme.txt

author-profile-widget/author-profile-widget.php Passed 13 tests

The main PHP file in "Author Profile Widget" ver. 0.4.2 adds more information about the plugin and also serves as the entry point for this plugin
65 characters long description:
Author Profile Widget add authors list widget and profile widget.

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | Executable files are not allowed as they can serve as attack vectors
Success! There were no dangerous files found in this plugin401 lines of code in 8 files:
LanguageFilesBlank linesComment linesLines of code
PHP636148338
PO File1192162
CSS1001

PHP code Passed 2 tests

Analyzing logical lines of code, cyclomatic complexity, and other code metrics
This plugin has no cyclomatic complexity problems
Cyclomatic complexity
Average complexity per logical line of code0.15
Average class complexity4.83
▷ Minimum class complexity1.00
▷ Maximum class complexity11.00
Average method complexity2.10
▷ Minimum method complexity1.00
▷ Maximum method complexity6.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes6
▷ Abstract classes00.00%
▷ Concrete classes6100.00%
▷ Final classes00.00%
Methods21
▷ Static methods00.00%
▷ Public methods1990.48%
▷ Protected methods14.76%
▷ Private methods14.76%
Functions0
▷ Named functions00.00%
▷ Anonymous functions00.00%
Constants1
▷ Global constants00.00%
▷ Class constants1100.00%
▷ Public constants1100.00%

Plugin size Passed 2 tests

Image compression Passed 2 tests

All PNG images should be compressed to minimize bandwidth usage for end users
PNG images were not found in this plugin