84% search-redirections

Code Review | Search Redirections

WordPress plugin Search Redirections scored84%from 54 tests.

About plugin

  • Plugin page: search-redirections
  • Plugin version: 0.1.3
  • PHP version: 7.4.16
  • WordPress compatibility: 5.0-6.3
  • WordPress version: 6.3.1
  • First release: Apr 21, 2015
  • Latest release: Aug 10, 2023
  • Number of updates: 54
  • Update frequency: every 56.2 days
  • Top authors: edersonpeka (100%)

Code review

54 tests

User reviews

1 review

Install metrics

80+ active /2,941 total downloads

Benchmarks

Plugin footprint 83% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | The install procedure must perform silently
Installer ran successfully

Server metrics [RAM: ▲0.06MB] [CPU: ▲0.56ms] Passed 4 tests

This is a short check of server-side resources used by Search Redirections
This plugin does not affect your website's performance
PageMemory (MB)CPU Time (ms)
Home /3.52 ▲0.0647.00 ▲4.96
Dashboard /wp-admin3.37 ▲0.0750.11 ▼0.12
Posts /wp-admin/edit.php3.49 ▲0.1350.64 ▼3.48
Add New Post /wp-admin/post-new.php5.95 ▲0.07101.26 ▲4.94
Media Library /wp-admin/upload.php3.29 ▲0.0739.01 ▲0.88
Search Redirections /wp-admin/options-general.php?page=search_redirections_options3.2735.00

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

How much does this plugin use your filesystem and database?
This plugin installed successfully
Filesystem: 7 new files
Database: no new tables, 6 new options
New WordPress options
can_compress_scripts
widget_recent-posts
theysaidso_admin_options
widget_theysaidso_widget
widget_recent-comments
db_upgraded

Browser metrics Passed 4 tests

An overview of browser requirements for Search Redirections
There were no issues detected in relation to browser resource usage
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,793 ▲714.35 ▲0.141.60 ▼0.5641.15 ▼7.37
Dashboard /wp-admin2,202 ▲255.62 ▼0.0194.67 ▲7.5336.92 ▼2.92
Posts /wp-admin/edit.php2,104 ▲41.98 ▼0.0440.12 ▼1.7735.05 ▼1.55
Add New Post /wp-admin/post-new.php1,529 ▲323.11 ▼0.42676.54 ▼10.8764.55 ▲12.55
Media Library /wp-admin/upload.php1,404 ▲44.11 ▼0.0998.53 ▼12.8043.40 ▼3.77
Search Redirections /wp-admin/options-general.php?page=search_redirections_options8851.6525.9125.55

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

🔸 Tests weight: 35 | The uninstall procedure must remove all plugin files and extra database tables
You still need to fix the following
  • Zombie WordPress options detected upon uninstall: 6 options
    • widget_recent-comments
    • widget_theysaidso_widget
    • can_compress_scripts
    • db_upgraded
    • theysaidso_admin_options
    • widget_recent-posts

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
Almost there! Just fix the following items
  • 1× GET requests to PHP files trigger server-side errors or Error 500 responses:
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_action() in wp-content/plugins/search-redirections/search-redirections.php:339

User-side errors Passed 1 test

🔹 Test weight: 20 | Just a short smoke test targeting errors on the browser (console and network errors and warnings)
No browser errors were detected

Optimizations

Plugin configuration Passed 29 tests

readme.txt Passed 16 tests

The readme.txt file is an important file in your plugin as it is parsed by WordPress.org to prepare the public listing of your plugin
4 plugin tags: search, search terms, redirection, redirect

search-redirections/search-redirections.php Passed 13 tests

The primary PHP file in "Search Redirections" version 0.1.3 is used by WordPress to initiate all plugin functionality
49 characters long description:
Create redirect rules for any given search terms.

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | An overview of files in this plugin; executable files are not allowed
Everything looks great! No dangerous files found in this plugin493 lines of code in 5 files:
LanguageFilesBlank linesComment linesLines of code
PHP12254267
JavaScript130131
PO File116038
CSS10035
Markdown112022

PHP code Passed 2 tests

Analyzing cyclomatic complexity and code structure
All good! No complexity issues found
Cyclomatic complexity
Average complexity per logical line of code0.29
Average class complexity29.00
▷ Minimum class complexity29.00
▷ Maximum class complexity29.00
Average method complexity2.67
▷ Minimum method complexity1.00
▷ Maximum method complexity10.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes1
▷ Abstract classes00.00%
▷ Concrete classes1100.00%
▷ Final classes00.00%
Methods16
▷ Static methods16100.00%
▷ Public methods16100.00%
▷ Protected methods00.00%
▷ Private methods00.00%
Functions2
▷ Named functions00.00%
▷ Anonymous functions2100.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
There were not PNG files found in your plugin