83% handle-external-links

Code Review | Handle External Links

WordPress plugin Handle External Links scored83%from 54 tests.

About plugin

  • Plugin page: handle-external-l...
  • Plugin version: 1.1.5
  • PHP version: 7.4.16
  • WordPress version: 6.3.1
  • First release: Dec 19, 2012
  • Latest release: Dec 21, 2012
  • Number of updates: 5
  • Update frequency: every 4.2 days
  • Top authors: getwebinspiration (100%)

Code review

54 tests

User reviews

3 reviews

Install metrics

10+ active /2,104 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
Installer ran successfully

Server metrics [RAM: ▼0.17MB] [CPU: ▼24.40ms] Passed 4 tests

Analyzing server-side resources used by Handle External Links
No issues were detected with server-side resource usage
PageMemory (MB)CPU Time (ms)
Home /4.06 ▲0.6031.18 ▼10.72
Dashboard /wp-admin3.36 ▲0.0146.69 ▼25.09
Posts /wp-admin/edit.php3.47 ▲0.1242.27 ▼9.89
Add New Post /wp-admin/post-new.php5.02 ▼0.8644.62 ▼51.88
Media Library /wp-admin/upload.php3.28 ▲0.0539.11 ▲7.16
Handle External Links /wp-admin/options-general.php?page=HandleEL3.2530.28

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

Input-output and database impact of this plugin
The plugin installed successfully
Filesystem: 22 new files
Database: no new tables, 8 new options
New WordPress options
theysaidso_admin_options
can_compress_scripts
widget_recent-comments
widget_theysaidso_widget
recovery_mode_email_last_sent
widget_recent-posts
HandleEL_entry
db_upgraded

Browser metrics Passed 4 tests

An overview of browser requirements for Handle External Links
Minimal impact on browser resources
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,817 ▲7113.61 ▼1.031.53 ▼0.3639.74 ▼3.77
Dashboard /wp-admin2,220 ▲324.89 ▼0.03104.60 ▼10.8641.56 ▼0.06
Posts /wp-admin/edit.php2,103 ▲172.22 ▲0.2138.23 ▲0.1832.55 ▲0.67
Add New Post /wp-admin/post-new.php45 ▼1,4830.44 ▼22.750.10 ▼691.509.98 ▼42.79
Media Library /wp-admin/upload.php1,402 ▲144.32 ▲0.10104.35 ▲4.4243.13 ▼2.08
Handle External Links /wp-admin/options-general.php?page=HandleEL1,0831.8431.1643.62

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

🔸 Tests weight: 35 | It is important to correctly uninstall your plugin, without leaving any traces
These items require your attention
  • This plugin does not fully uninstall, leaving 8 options in the database
    • HandleEL_entry
    • can_compress_scripts
    • widget_recent-comments
    • theysaidso_admin_options
    • widget_theysaidso_widget
    • widget_recent-posts
    • recovery_mode_email_last_sent
    • db_upgraded

Smoke tests 75% from 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | A smoke test targeting server-side errors
Everything seems fine, however this is by no means an exhaustive test

SRP 50% from 2 tests

🔹 Tests weight: 20 | A shallow check of the single-responsibility principle; PHP files should perform no action - including output of placeholder text - and trigger no errors when accessed directly
Please take a closer look at the following
  • 1× PHP files trigger server-side errors or warnings when accessed directly:
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_action() in wp-content/plugins/handle-external-links/handleEL.php:129

User-side errors Passed 1 test

🔹 Test weight: 20 | This is just a short smoke test looking for browser issues
Everything seems fine, but this is not an exhaustive test

Optimizations

Plugin configuration 83% from 29 tests

readme.txt 81% from 16 tests

The readme.txt file describes your plugin functionality and requirements and it is parsed to prepare the your plugin's listing
Attributes that require attention:
  • Tags: Please reduce the number of tags, currently 15 tag instead of maximum 10
  • Screenshots: These screenshots have no corresponding images in /assets: #1 (Options page from the Dashboard.), #2 (Sample post with settings applied.)
  • Requires at least: Version not formatted correctly
The official readme.txt is a good inspiration

handle-external-links/handleEL.php 85% from 13 tests

The main PHP file in "Handle External Links" ver. 1.1.5 adds more information about the plugin and also serves as the entry point for this plugin
Please make the necessary changes and fix the following:
  • Main file name: It is recommended to name the main PHP file as the plugin slug ("handle-external-links.php" instead of "handleEL.php")
  • Description: Please don't use more than 140 characters for the plugin description (currently 221 characters long)

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | There should be no dangerous file extensions present in any WordPress plugin
Everything looks great! No dangerous files found in this plugin2,048 lines of code in 5 files:
LanguageFilesBlank linesComment linesLines of code
PHP32513781,656
CSS14344387
JavaScript1005

PHP code Passed 2 tests

This plugin's cyclomatic complexity and code structure detailed below
Everything seems fine, there were no complexity issues found
Cyclomatic complexity
Average complexity per logical line of code0.49
Average class complexity64.83
▷ Minimum class complexity9.00
▷ Maximum class complexity197.00
Average method complexity4.51
▷ Minimum method complexity1.00
▷ Maximum method complexity57.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes6
▷ Abstract classes00.00%
▷ Concrete classes6100.00%
▷ Final classes00.00%
Methods109
▷ Static methods10.92%
▷ Public methods9385.32%
▷ Protected methods1614.68%
▷ Private methods00.00%
Functions3
▷ Named functions3100.00%
▷ Anonymous functions00.00%
Constants22
▷ Global constants2195.45%
▷ Class constants14.55%
▷ Public constants1100.00%

Plugin size Passed 2 tests

Image compression Passed 2 tests

PNG files should be compressed to save space and minimize bandwidth usage
15 PNG files occupy 0.12MB with 0.03MB in potential savings
Potential savings
Compression of 5 random PNG files using pngquant
FileSize - originalSize - compressedSavings
css/images/ui-bg_glass_55_fbf9ee_1x400.png0.12KB0.14KB0.00%
css/images/ui-bg_highlight-soft_75_cccccc_1x100.png0.10KB0.17KB0.00%
css/images/ui-bg_flat_0_aaaaaa_40x100.png0.18KB0.08KB▼ 51.67%
css/images/ui-bg_glass_65_ffffff_1x400.png0.10KB0.10KB▼ 5.71%
screenshot-1.png50.70KB24.75KB▼ 51.18%