73% premium-link-cloaker-lite

Code Review | Premium Link Cloaker Lite

WordPress plugin Premium Link Cloaker Lite scored 73% from 54 tests.

About plugin

  • Plugin page: premium-link-cloa...
  • Plugin version: 1.0
  • PHP version: 7.4.16
  • WordPress compatibility: 4.0-4.6.1
  • WordPress version: 6.3.1
  • First release: Mar 24, 2016
  • Latest release: Oct 23, 2016
  • Number of updates: 5
  • Update frequency: every 42.6 days
  • Top authors: maurisrx (100%)

Code review

54 tests

User reviews

1 review

Install metrics

10+ active / 1,345 total downloads

Benchmarks

Plugin footprint 65% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | All plugins must install correctly, without throwing any errors, warnings, or notices
This plugin's installer ran successfully

Server metrics [RAM: ▲0.03MB] [CPU: ▼4.06ms] Passed 4 tests

Server-side resources used by Premium Link Cloaker Lite
Server-side resource usage in normal parameters
PageMemory (MB)CPU Time (ms)
Home /3.48 ▲0.0236.89 ▼5.28
Dashboard /wp-admin3.34 ▲0.0447.86 ▼3.69
Posts /wp-admin/edit.php3.39 ▲0.0350.09 ▲1.84
Add New Post /wp-admin/post-new.php5.92 ▲0.0388.43 ▼8.99
Media Library /wp-admin/upload.php3.26 ▲0.0336.05 ▲1.72
Go PRO /wp-admin/admin.php?page=plcl_go_pro3.2832.06
Stats /wp-admin/admin.php?page=plcl_stats3.3238.38
Add New Link /wp-admin/admin.php?page=plcl_add_link3.3034.74
Categories /wp-admin/admin.php?page=plcl_categories3.3029.58
Settings /wp-admin/admin.php?page=plcl_settings3.2932.22
Cloaked Links /wp-admin/admin.php?page=plcl3.3332.35

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

Filesystem and database footprint
This plugin was installed successfully
Filesystem: 29 new files
Database: 4 new tables, 7 new options
New tables
wp_plcl_cat_relationships
wp_plcl_categories
wp_plcl_clicks
wp_plcl_links
New WordPress options
widget_recent-comments
theysaidso_admin_options
can_compress_scripts
widget_theysaidso_widget
plcl_settings
widget_recent-posts
db_upgraded

Browser metrics Passed 4 tests

Checking browser requirements for Premium Link Cloaker Lite
This plugin renders optimally with no browser resource issues detected
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,843 ▲10813.27 ▼1.091.61 ▼0.1741.52 ▼2.65
Dashboard /wp-admin2,249 ▲615.90 ▲0.99106.33 ▼12.5239.27 ▼8.25
Posts /wp-admin/edit.php2,129 ▲402.01 ▼0.0542.20 ▲7.7334.41 ▲0.74
Add New Post /wp-admin/post-new.php1,567 ▲4723.52 ▲0.43658.71 ▼29.4356.11 ▼10.32
Media Library /wp-admin/upload.php1,434 ▲464.19 ▼0.0396.00 ▼17.0843.37 ▼5.64
Go PRO /wp-admin/admin.php?page=plcl_go_pro1,0312.3831.8054.97
Stats /wp-admin/admin.php?page=plcl_stats1,1632.5037.7533.17
Add New Link /wp-admin/admin.php?page=plcl_add_link1,0672.3930.7627.41
Categories /wp-admin/admin.php?page=plcl_categories1,0932.3831.3530.12
Settings /wp-admin/admin.php?page=plcl_settings1,0842.3830.8828.00
Cloaked Links /wp-admin/admin.php?page=plcl1,1622.5240.8531.24

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

🔸 Tests weight: 35 | Verifying that this plugin uninstalls completely without leaving any traces
Please fix the following items
  • The plugin did not uninstall successfully, leaving 4 tables in the database
    • wp_plcl_clicks
    • wp_plcl_categories
    • wp_plcl_cat_relationships
    • wp_plcl_links
  • Zombie WordPress options detected upon uninstall: 7 options
    • plcl_settings
    • theysaidso_admin_options
    • can_compress_scripts
    • widget_theysaidso_widget
    • widget_recent-posts
    • db_upgraded
    • widget_recent-comments

Smoke tests 75% from 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | A smoke test targeting server-side errors
The smoke test was a success, however most plugin functionality was not tested

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
The following issues need your attention
  • 10× PHP files trigger server errors when accessed directly:
    • > PHP Fatal error
      Uncaught Error: Call to undefined function premium_link_cloaker_lite() in wp-content/plugins/premium-link-cloaker-lite/templates/admin/settings.php:1
    • > PHP Fatal error
      Uncaught Error: Call to undefined function _e() in wp-content/plugins/premium-link-cloaker-lite/templates/admin/sidebar.php:7
    • > PHP Fatal error
      Uncaught Error: Call to undefined function _e() in wp-content/plugins/premium-link-cloaker-lite/templates/admin/categories.php:8
    • > PHP Fatal error
      Uncaught Error: Call to undefined function _e() in wp-content/plugins/premium-link-cloaker-lite/templates/admin/go-pro.php:7
    • > PHP Fatal error
      Uncaught Error: Call to undefined function _e() in wp-content/plugins/premium-link-cloaker-lite/templates/admin/edit-link.php:7
    • > PHP Fatal error
      Uncaught Error: Call to undefined function __() in wp-content/plugins/premium-link-cloaker-lite/templates/admin/link-form.php:1
    • > PHP Fatal error
      Uncaught Error: Call to undefined function __() in wp-content/plugins/premium-link-cloaker-lite/templates/admin/cat-form.php:1
    • > PHP Fatal error
      Uncaught Error: Call to undefined function __() in wp-content/plugins/premium-link-cloaker-lite/templates/admin/stats.php:2
    • > PHP Fatal error
      Uncaught Error: Call to undefined function _e() in wp-content/plugins/premium-link-cloaker-lite/templates/admin/links.php:13
    • > PHP Fatal error
      Uncaught Error: Call to undefined function _e() in wp-content/plugins/premium-link-cloaker-lite/templates/admin/add-link.php:7

User-side errors Passed 1 test

🔹 Test weight: 20 | This is a shallow check for browser errors
No browser errors were detected

Optimizations

Plugin configuration 86% from 29 tests

readme.txt 94% from 16 tests

Don't ignore readme.txt as it is the file that instructs WordPress.org on how to present your plugin to the world
Attributes that require attention:
  • Screenshots: Screenshot #1 (PLC Lite dashboard) image not found
Please take inspiration from this readme.txt

premium-link-cloaker-lite/premium-link-cloaker-lite.php 77% from 13 tests

The main PHP file in "Premium Link Cloaker Lite" ver. 1.0 adds more information about the plugin and also serves as the entry point for this plugin
Please take the time to fix the following:
  • Domain Path: Prefix the domain path with a forward slash character ("/languages")
  • Domain Path: You should use only dashes and lowercase characters for the domain path ("languages")
  • Description: The description should be shorter than 140 characters (currently 225 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
No dangerous file extensions were detected2,011 lines of code in 24 files:
LanguageFilesBlank linesComment linesLines of code
PHP172401191,818
CSS3303127
JavaScript452266

PHP code Passed 2 tests

Cyclomatic complexity and code structure are the fingerprint of this plugin
There are no cyclomatic complexity problems detected for this plugin
Cyclomatic complexity
Average complexity per logical line of code0.34
Average class complexity21.50
▷ Minimum class complexity3.00
▷ Maximum class complexity43.00
Average method complexity3.16
▷ Minimum method complexity1.00
▷ Maximum method complexity19.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes6
▷ Abstract classes00.00%
▷ Concrete classes6100.00%
▷ Final classes116.67%
Methods57
▷ Static methods11.75%
▷ Public methods5494.74%
▷ Protected methods00.00%
▷ Private methods35.26%
Functions1
▷ Named functions1100.00%
▷ Anonymous functions00.00%
Constants5
▷ Global constants5100.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
1 PNG file occupies 0.04MB with 0.02MB in potential savings
Potential savings
Compression of 1 random PNG file using pngquant
FileSize - originalSize - compressedSavings
screenshot-1.png42.67KB17.55KB▼ 58.86%