84% go-redirects

Code Review | Go Redirects URL Forwarder

WordPress plugin Go Redirects URL Forwarder scored84%from 54 tests.

About plugin

  • Plugin page: go-redirects
  • Plugin version: 2.0.3
  • PHP compatiblity: 5.4+
  • PHP version: 7.4.16
  • WordPress compatibility: 4.7-5.8
  • WordPress version: 6.3.1
  • First release: Oct 23, 2014
  • Latest release: Aug 4, 2021
  • Number of updates: 25
  • Update frequency: every 99.1 days
  • Top authors: GalenGidman (80%)wpkube (24%)

Code review

54 tests

User reviews

4 reviews

Install metrics

1,000+ active /22,758 total downloads

Benchmarks

Plugin footprint 83% from 16 tests

Installer Passed 1 test

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

Server metrics [RAM: ▲0.55MB] [CPU: ▼3.24ms] Passed 4 tests

A check of server-side resources used by Go Redirects URL Forwarder
No issues were detected with server-side resource usage
PageMemory (MB)CPU Time (ms)
Home /3.82 ▲0.3641.49 ▼6.61
Dashboard /wp-admin3.94 ▲0.6050.12 ▼11.91
Posts /wp-admin/edit.php3.97 ▲0.6146.76 ▲0.44
Add New Post /wp-admin/post-new.php6.54 ▲0.6599.00 ▲7.07
Media Library /wp-admin/upload.php3.87 ▲0.6439.72 ▲5.14
All Redirects /wp-admin/edit.php?post_type=gr_redirect3.9238.43
Add New /wp-admin/post-new.php?post_type=gr_redirect4.1352.33

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

Analyzing filesystem and database footprints of this plugin
No storage issues were detected
Filesystem: 380 new files
Database: no new tables, 6 new options
New WordPress options
widget_recent-comments
theysaidso_admin_options
widget_theysaidso_widget
can_compress_scripts
widget_recent-posts
db_upgraded

Browser metrics Passed 4 tests

This is an overview of browser requirements for Go Redirects URL Forwarder
Normal browser usage
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,830 ▲8414.69 ▲0.071.72 ▼0.2142.61 ▼1.43
Dashboard /wp-admin2,230 ▲505.60 ▼0.01104.17 ▲16.1342.96 ▲6.62
Posts /wp-admin/edit.php2,138 ▲382.03 ▲0.0235.85 ▼0.5032.25 ▼0.58
Add New Post /wp-admin/post-new.php1,556 ▲3023.71 ▲0.64599.24 ▼8.0863.75 ▼0.06
Media Library /wp-admin/upload.php1,441 ▲384.28 ▲0.0897.70 ▼10.2743.13 ▼5.43
All Redirects /wp-admin/edit.php?post_type=gr_redirect1,1272.0333.9526.99
Add New /wp-admin/post-new.php?post_type=gr_redirect1,5232.6160.5871.56

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

🔸 Tests weight: 35 | Checking the uninstaller removed all traces of the plugin
You still need to fix the following
  • Zombie WordPress options detected upon uninstall: 6 options
    • widget_recent-comments
    • db_upgraded
    • can_compress_scripts
    • widget_theysaidso_widget
    • theysaidso_admin_options
    • widget_recent-posts

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)
Everything seems fine, however this is by no means 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 items
  • 39× GET requests to PHP files trigger server-side errors or Error 500 responses (only 10 are shown):
    • > PHP Fatal error
      Uncaught Error: Class 'CMB2_Hookup_Base' not found in wp-content/plugins/go-redirects/includes/vendor/cmb2/includes/rest-api/CMB2_REST.php:19
    • > PHP Fatal error
      Uncaught Error: Class 'CMB2_Base' not found in wp-content/plugins/go-redirects/includes/vendor/cmb2/includes/CMB2_Field.php:17
    • > PHP Fatal error
      Uncaught Error: Class 'CMB2_Type_Textarea' not found in wp-content/plugins/go-redirects/includes/vendor/cmb2/includes/types/CMB2_Type_Textarea_Code.php:13
    • > PHP Fatal error
      Uncaught Error: Class 'CMB2_Type_Taxonomy_Radio' not found in wp-content/plugins/go-redirects/includes/vendor/cmb2/includes/types/CMB2_Type_Taxonomy_Radio_Hierarchical.php:13
    • > PHP Fatal error
      Uncaught Error: Class 'CMB2_hookup' not found in wp-content/plugins/go-redirects/includes/vendor/cmb2/includes/CMB2_Options_Hookup.php:14
    • > PHP Fatal error
      Uncaught Error: Class 'CMB2_Type_Text_Date' not found in wp-content/plugins/go-redirects/includes/vendor/cmb2/includes/types/CMB2_Type_Text_Time.php:13
    • > PHP Fatal error
      Uncaught Error: Class 'CMB2_Type_Base' not found in wp-content/plugins/go-redirects/includes/vendor/cmb2/includes/types/CMB2_Type_Multi_Base.php:13
    • > PHP Fatal error
      Uncaught Error: Class 'CMB2_Type_Multi_Base' not found in wp-content/plugins/go-redirects/includes/vendor/cmb2/includes/types/CMB2_Type_Select.php:13
    • > PHP Fatal error
      Uncaught Error: Class 'CMB2_Type_Taxonomy_Multicheck' not found in wp-content/plugins/go-redirects/includes/vendor/cmb2/includes/types/CMB2_Type_Taxonomy_Multicheck_Hierarchical.php:13
    • > PHP Fatal error
      Uncaught Error: Class 'CMB2_Type_Multi_Base' not found in wp-content/plugins/go-redirects/includes/vendor/cmb2/includes/types/CMB2_Type_Radio.php:13

User-side errors Passed 1 test

🔹 Test weight: 20 | This is a shallow check for browser errors
Everything seems fine, but this is not an exhaustive test

Optimizations

Plugin configuration Passed 29 tests

readme.txt Passed 16 tests

The readme.txt file uses markdown syntax to describe your plugin to the world
5 plugin tags: redirects, affiliate link, affiliate, redirect, url mask

go-redirects/go-redirects.php Passed 13 tests

The primary PHP file in "Go Redirects URL Forwarder" version 2.0.3 is used by WordPress to initiate all plugin functionality
39 characters long description:
A super-simple URL forwarder WordPress.

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 detected48,898 lines of code in 231 files:
LanguageFilesBlank linesComment linesLines of code
PO File12013,78717,89031,582
PHP662,4226,1337,553
CSS151,1721,1775,121
JavaScript123839572,752
Sass15291251,330
Markdown31910560

PHP code Passed 2 tests

An overview of cyclomatic complexity and code structure
There are no cyclomatic complexity problems detected for this plugin
Cyclomatic complexity
Average complexity per logical line of code0.48
Average class complexity19.43
▷ Minimum class complexity1.00
▷ Maximum class complexity182.00
Average method complexity3.36
▷ Minimum method complexity1.00
▷ Maximum method complexity40.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes68
▷ Abstract classes811.76%
▷ Concrete classes6088.24%
▷ Final classes00.00%
Methods535
▷ Static methods8115.14%
▷ Public methods44482.99%
▷ Protected methods8816.45%
▷ Private methods30.56%
Functions45
▷ Named functions45100.00%
▷ Anonymous functions00.00%
Constants14
▷ Global constants857.14%
▷ Class constants642.86%
▷ Public constants6100.00%

Plugin size Passed 2 tests

Image compression Passed 2 tests

All PNG images should be compressed to minimize bandwidth usage for end users
14 compressed PNG files occupy 0.02MB
Potential savings
Compression of 5 random PNG files using pngquant
FileSize - originalSize - compressedSavings
includes/vendor/cmb2/images/ui-bg_flat_0_aaaaaa_40x100.png0.18KB0.08KB▼ 51.67%
includes/vendor/cmb2/images/ui-icons_222222_256x240.png4.27KB4.11KB▼ 3.78%
includes/vendor/cmb2/images/ico-delete.png0.70KB0.72KB0.00%
includes/vendor/cmb2/images/ui-bg_glass_75_dadada_1x400.png0.11KB0.16KB0.00%
includes/vendor/cmb2/images/ui-icons_2e83ff_256x240.png4.27KB4.11KB▼ 3.78%