84% regenerate-post-permalinks

Code Review | Regenerate post permalink

WordPress plugin Regenerate post permalink scored84%from 54 tests.

About plugin

  • Plugin page: regenerate-post-p...
  • Plugin version: 1.0.3
  • PHP version: 7.4.16
  • WordPress compatibility: 3.1.0-4.7
  • WordPress version: 6.3.1
  • First release: Aug 8, 2013
  • Latest release: Dec 10, 2016
  • Number of updates: 16
  • Update frequency: every 76.3 days
  • Top authors: almos20 (100%)

Code review

54 tests

User reviews

11 reviews

Install metrics

10,000+ active /17,773 total downloads

Benchmarks

Plugin footprint 83% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | It is important to correctly install your plugin, without throwing errors or notices
Install script ran successfully

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

A check of server-side resources used by Regenerate post permalink
This plugin does not affect your website's performance
PageMemory (MB)CPU Time (ms)
Home /3.49 ▲0.0238.45 ▼3.55
Dashboard /wp-admin3.33 ▼0.0251.21 ▼15.31
Posts /wp-admin/edit.php3.38 ▲0.0251.70 ▲3.64
Add New Post /wp-admin/post-new.php5.91 ▲0.0297.35 ▼15.03
Media Library /wp-admin/upload.php3.26 ▲0.0240.80 ▼4.65
Permalink regeneration /wp-admin/options-general.php?page=regenerate-post-permalink3.2232.50

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

Input-output and database impact of this plugin
This plugin was installed successfully
Filesystem: 2 new files
Database: no new tables, 6 new options
New WordPress options
theysaidso_admin_options
widget_theysaidso_widget
widget_recent-posts
can_compress_scripts
db_upgraded
widget_recent-comments

Browser metrics Passed 4 tests

Regenerate post permalink: an overview of browser usage
There were no issues detected in relation to browser resource usage
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,793 ▲4714.28 ▼0.081.89 ▲0.3040.90 ▼2.22
Dashboard /wp-admin2,199 ▲225.65 ▼0.0089.34 ▼2.7742.55 ▲2.45
Posts /wp-admin/edit.php2,104 ▲12.00 ▲0.0339.02 ▲4.5736.62 ▼0.80
Add New Post /wp-admin/post-new.php1,531 ▼022.99 ▼0.22627.10 ▼59.2170.28 ▲4.88
Media Library /wp-admin/upload.php1,404 ▲44.20 ▼0.03100.08 ▼20.7541.10 ▼7.95
Permalink regeneration /wp-admin/options-general.php?page=regenerate-post-permalink8402.1223.8531.20

Uninstaller [IO: ▲0.00MB] [DB: ▲0.00MB] 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
    • can_compress_scripts
    • theysaidso_admin_options
    • widget_theysaidso_widget
    • db_upgraded
    • widget_recent-comments

Smoke tests 75% from 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | This is a shallow check for server-side errors
Everything seems fine, however 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
  • 1× PHP files trigger server-side errors or warnings when accessed directly:
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_action() in wp-content/plugins/regenerate-post-permalinks/regenerate-post-permalink.php:12

User-side errors Passed 1 test

🔹 Test weight: 20 | This is a smoke test targeting browser errors/issues
There were no browser issues found

Optimizations

Plugin configuration 96% from 29 tests

readme.txt Passed 16 tests

Often overlooked, readme.txt is one of the most important files in your plugin
2 plugin tags: permalinks, post

regenerate-post-permalinks/regenerate-post-permalink.php 92% from 13 tests

The principal PHP file in "Regenerate post permalink" v. 1.0.3 is loaded by WordPress automatically on each request
It is important to fix the following:
  • Main file name: Name the main plugin file the same as the plugin slug ("regenerate-post-permalinks.php" instead of "regenerate-post-permalink.php")

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | This is a short overview of programming languages used in this plugin, detecting executable files
There were no executable files found in this plugin89 lines of code in 1 file:
LanguageFilesBlank linesComment linesLines of code
PHP1221189

PHP code Passed 2 tests

An short overview of logical lines of code, cyclomatic complexity, and other code metrics
This plugin has no cyclomatic complexity issues
Cyclomatic complexity
Average complexity per logical line of code0.14
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%
Functions4
▷ Named functions4100.00%
▷ Anonymous functions00.00%
Constants0
▷ Global constants00.00%
▷ Class constants00.00%
▷ Public constants00.00%

Plugin size Passed 2 tests

Image compression Passed 2 tests

Using a strong compression for your PNG files is a great way to speed-up your plugin
PNG images were not found in this plugin