90% wp-redirect-404s-to-homepage

Code Review | WP Redirect 404s To Homepage

WordPress plugin WP Redirect 404s To Homepage scored90%from 54 tests.

About plugin

  • Plugin page: wp-redirect-404s-...
  • Plugin version: 1.1
  • PHP version: 7.4.16
  • WordPress compatibility: 4.3-5.2
  • WordPress version: 6.3.1
  • First release: Jun 3, 2019
  • Latest release: Jun 3, 2019
  • Number of updates: 2
  • Update frequency: every 1.0 days
  • Top authors: eastsidecode (100%)

Code review

54 tests

User reviews

1 review

Install metrics

10+ active /434 total downloads

Benchmarks

Plugin footprint 83% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | All plugins must install correctly, without throwing any errors, warnings, or notices
Install script ran successfully

Server metrics [RAM: ▼0.01MB] [CPU: ▼11.14ms] Passed 4 tests

A check of server-side resources used by WP Redirect 404s To Homepage
This plugin does not affect your website's performance
PageMemory (MB)CPU Time (ms)
Home /3.47 ▲0.0039.79 ▼5.35
Dashboard /wp-admin3.31 ▼0.0446.28 ▼16.17
Posts /wp-admin/edit.php3.36 ▲0.0045.08 ▼3.61
Add New Post /wp-admin/post-new.php5.89 ▲0.0086.23 ▼19.44
Media Library /wp-admin/upload.php3.23 ▲0.0039.84 ▲3.55

Server storage [IO: ▲0.00MB] [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: 2 new files
Database: no new tables, 6 new options
New WordPress options
db_upgraded
widget_recent-posts
can_compress_scripts
widget_recent-comments
widget_theysaidso_widget
theysaidso_admin_options

Browser metrics Passed 4 tests

This is an overview of browser requirements for WP Redirect 404s To Homepage
Normal browser usage
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,814 ▲2814.75 ▲0.442.19 ▲0.2046.03 ▲5.85
Dashboard /wp-admin2,192 ▲125.55 ▼0.1784.41 ▼4.4139.28 ▼3.41
Posts /wp-admin/edit.php2,100 ▼31.98 ▼0.0136.01 ▼1.3834.21 ▼7.09
Add New Post /wp-admin/post-new.php1,526 ▼617.47 ▼5.69677.71 ▼1.6854.36 ▲1.42
Media Library /wp-admin/upload.php1,403 ▼04.25 ▲0.03106.03 ▼0.0949.11 ▲1.97

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

🔸 Tests weight: 35 | Verifying that this plugin uninstalls completely without leaving any traces
Please fix the following items
  • Zombie WordPress options were found after uninstall: 6 options
    • can_compress_scripts
    • widget_theysaidso_widget
    • widget_recent-posts
    • db_upgraded
    • theysaidso_admin_options
    • widget_recent-comments

Smoke tests Passed 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 Passed 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
Congratulations! This plugin passed the SRP test

User-side errors Passed 1 test

🔹 Test weight: 20 | This is a shallow check for browser errors
Everything seems fine on the user side

Optimizations

Plugin configuration 96% from 29 tests

readme.txt Passed 16 tests

Perhaps the most important file in your plugin readme.txt gets parsed in order to generate the public listing of your plugin
2 plugin tags: redirect, 404s

wp-redirect-404s-to-homepage/index.php 92% from 13 tests

The main file in "WP Redirect 404s To Homepage" v. 1.1 serves as a complement to information provided in readme.txt and as the entry point to the plugin
You should first fix the following items:
  • Main file name: Please rename the main PHP file in this plugin to the plugin slug ("wp-redirect-404s-to-homepage.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
Good job! No executable or dangerous file extensions detected10 lines of code in 1 file:
LanguageFilesBlank linesComment linesLines of code
PHP111910

PHP code Passed 2 tests

An overview of cyclomatic complexity and code structure
There were no cyclomatic complexity issued detected
Cyclomatic complexity
Average complexity per logical line of code0.40
Average class complexity0.00
▷ Minimum class complexity0.00
▷ Maximum class complexity0.00
Average method complexity0.00
▷ Minimum method complexity0.00
▷ Maximum method complexity0.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes0
▷ Abstract classes00.00%
▷ Concrete classes00.00%
▷ Final classes00.00%
Methods0
▷ Static methods00.00%
▷ Public methods00.00%
▷ Protected methods00.00%
▷ Private methods00.00%
Functions1
▷ Named functions1100.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