84% let-me-redirect

Code Review | Let Me Redirect

WordPress plugin Let Me Redirect scored84%from 54 tests.

About plugin

  • Plugin page: let-me-redirect
  • Plugin version: 1.0.4
  • PHP version: 7.4.16
  • WordPress compatibility: 3.0-4.7
  • WordPress version: 6.3.1
  • First release: Nov 23, 2016
  • Latest release: Jan 6, 2017
  • Number of updates: 18
  • Update frequency: every 2.3 days
  • Top authors: megrithemes (100%)

Code review

54 tests

User reviews

5 reviews

Install metrics

10+ active /993 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 gracefully, with no errors

Server metrics [RAM: ▲0.00MB] [CPU: ▼6.73ms] Passed 4 tests

Server-side resources used by Let Me Redirect
No issues were detected with server-side resource usage
PageMemory (MB)CPU Time (ms)
Home /3.46 ▲0.0040.09 ▼0.31
Dashboard /wp-admin3.31 ▲0.0045.03 ▼17.66
Posts /wp-admin/edit.php3.36 ▲0.0046.71 ▼1.76
Add New Post /wp-admin/post-new.php5.89 ▲0.0084.41 ▼7.19
Media Library /wp-admin/upload.php3.23 ▲0.0035.03 ▲0.01

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

How much does this plugin use your filesystem and database?
There were no storage issued detected upon installing this plugin
Filesystem: 8 new files
Database: no new tables, 6 new options
New WordPress options
theysaidso_admin_options
db_upgraded
widget_recent-comments
widget_recent-posts
can_compress_scripts
widget_theysaidso_widget

Browser metrics Passed 4 tests

An overview of browser requirements for Let Me Redirect
This plugin renders optimally with no browser resource issues detected
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,800 ▲6513.28 ▼1.001.99 ▲0.1743.42 ▼7.46
Dashboard /wp-admin2,206 ▲154.85 ▼0.05107.36 ▼7.5041.75 ▼5.76
Posts /wp-admin/edit.php2,089 ▼02.04 ▲0.0139.16 ▲2.7536.04 ▲1.18
Add New Post /wp-admin/post-new.php1,533 ▲423.08 ▲5.08652.63 ▲13.8452.43 ▼1.61
Media Library /wp-admin/upload.php1,391 ▲34.18 ▼0.08101.37 ▲7.1444.70 ▲4.86

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

🔸 Tests weight: 35 | All plugins must uninstall correctly, removing their source code and extra database tables they might have created
The following items require your attention
  • Zombie WordPress options detected upon uninstall: 6 options
    • widget_recent-posts
    • widget_theysaidso_widget
    • theysaidso_admin_options
    • db_upgraded
    • widget_recent-comments
    • can_compress_scripts

Smoke tests 75% from 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | A smoke test targeting server-side errors
Even though no errors were found, this is by no means an exhaustive test

SRP 50% 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
  • 5× PHP files trigger server errors when accessed directly:
    • > PHP Fatal error
      Uncaught Error: Call to undefined function register_activation_hook() in wp-content/plugins/let-me-redirect/security/schedule.php:4
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_filter() in wp-content/plugins/let-me-redirect/security/overview.php:132
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_action() in wp-content/plugins/let-me-redirect/security/fields.php:4
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_filter() in wp-content/plugins/let-me-redirect/security/report.php:4
    • > PHP Fatal error
      Uncaught Error: Call to undefined function plugin_dir_path() in wp-content/plugins/let-me-redirect/index.php:11

User-side errors Passed 1 test

🔹 Test weight: 20 | This is just a short smoke test looking for browser issues
Everything seems fine on the user side

Optimizations

Plugin configuration 93% from 29 tests

readme.txt Passed 16 tests

The readme.txt file describes your plugin functionality and requirements and it is parsed to prepare the your plugin's listing
6 plugin tags: external redirect, 307, site redirection, internal redirect, redirect...

let-me-redirect/index.php 85% from 13 tests

"Let Me Redirect" version 1.0.4's primary PHP file adds more information about the plugin and serves as the entry point for WordPress
Please make the necessary changes and fix the following:
  • Description: The description should be shorter than 140 characters (currently 290 characters long)
  • Main file name: Please rename the main PHP file in this plugin to the plugin slug ("let-me-redirect.php" instead of "index.php")

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
Everything looks great! No dangerous files found in this plugin3,678 lines of code in 7 files:
LanguageFilesBlank linesComment linesLines of code
PHP73522913,678

PHP code Passed 2 tests

A short review of cyclomatic complexity and code structure
Everything seems fine, there were no complexity issues found
Cyclomatic complexity
Average complexity per logical line of code0.48
Average class complexity548.00
▷ Minimum class complexity548.00
▷ Maximum class complexity548.00
Average method complexity10.60
▷ Minimum method complexity1.00
▷ Maximum method complexity60.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes1
▷ Abstract classes00.00%
▷ Concrete classes1100.00%
▷ Final classes00.00%
Methods57
▷ Static methods00.00%
▷ Public methods57100.00%
▷ Protected methods00.00%
▷ Private methods00.00%
Functions56
▷ Named functions56100.00%
▷ Anonymous functions00.00%
Constants0
▷ Global constants00.00%
▷ Class constants00.00%
▷ Public constants00.00%

Plugin size Passed 2 tests

Image compression Passed 2 tests

All PNG images should be compressed to minimize bandwidth usage for end users
No PNG files were detected