10% enhanced-custom-permalinks

Code Review | Enhanced Custom Permalinks

WordPress plugin Enhanced Custom Permalinks scored10%from 54 tests.

About plugin

  • Plugin page: enhanced-custom-p...
  • Plugin version: 0.1.1
  • PHP version: 7.4.16
  • WordPress compatibility: 3.0-4.0.1
  • WordPress version: 6.3.1
  • First release: Mar 7, 2014
  • Latest release: Sep 23, 2014
  • Number of updates: 4
  • Update frequency: every 50.0 days
  • Top authors: kasigi (100%)

Code review

54 tests

User reviews

14 reviews

Install metrics

2,000+ active /12,734 total downloads

Benchmarks

Plugin footprint 40% from 16 tests

Installer 0% from 1 test

🔺 Critical test (weight: 50) | The install procedure must perform silently
These installer errors require your attention
  • Install procedure had errors
    • > Deprecated in wp-content/plugins/enhanced-custom-permalinks/enh-custom-permalinks.php+331
    Array and string offset access syntax with curly braces is deprecated

Server metrics [RAM: ▼1.72MB] [CPU: ▼52.94ms] Passed 4 tests

This is a short check of server-side resources used by Enhanced Custom Permalinks
This plugin does not affect your website's performance
PageMemory (MB)CPU Time (ms)
Home /2.28 ▼1.194.36 ▼41.95
Dashboard /wp-admin2.30 ▼1.055.35 ▼53.79
Posts /wp-admin/edit.php2.30 ▼1.066.81 ▼38.97
Add New Post /wp-admin/post-new.php2.30 ▼3.595.63 ▼77.04
Media Library /wp-admin/upload.php2.30 ▼0.947.02 ▼29.71
Custom Permalinks /wp-admin/tools.php?page=custom_permalinks2.305.08

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

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

Browser metrics Passed 4 tests

Enhanced Custom Permalinks: an overview of browser usage
Normal browser usage
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,804 ▲5813.27 ▼1.114.78 ▲3.0437.14 ▼6.61
Dashboard /wp-admin2,210 ▲674.87 ▼0.81114.83 ▲19.3743.29 ▲1.37
Posts /wp-admin/edit.php2,096 ▲42.05 ▲0.0240.04 ▲5.2934.61 ▲4.61
Add New Post /wp-admin/post-new.php1,536 ▲323.24 ▲0.15667.76 ▲10.3053.42 ▲7.23
Media Library /wp-admin/upload.php1,389 ▼24.21 ▼0.0794.05 ▲1.1839.64 ▼6.29
Custom Permalinks /wp-admin/tools.php?page=custom_permalinks7962.0625.5727.72

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

🔸 Tests weight: 35 | Checking the uninstaller removed all traces of the plugin
The following items require your attention
  • Uninstall procedure validation failed for this plugin
    • > Deprecated in wp-content/plugins/enhanced-custom-permalinks/enh-custom-permalinks.php+331
    Array and string offset access syntax with curly braces is deprecated
  • Zombie WordPress options detected upon uninstall: 6 options
    • widget_theysaidso_widget
    • widget_recent-posts
    • can_compress_scripts
    • widget_recent-comments
    • theysaidso_admin_options
    • db_upgraded

Smoke tests 50% from 4 tests

Server-side errors 0% from 1 test

🔹 Test weight: 20 | This is a shallow check for server-side errors
Smoke test failed, please fix the following
    • > GET request to /wp-admin/tools.php?page=custom_permalinks
    • > Deprecated in wp-content/plugins/enhanced-custom-permalinks/enh-custom-permalinks.php+331
    Array and string offset access syntax with curly braces is deprecated
  • 2 occurences, only the last one shown
    • > GET request to /wp-admin/tools.php?page=custom_permalinks
    • > User deprecated in wp-includes/functions.php+5737
    Function has_cap was called with an argument that is deprecated since version 2.0.0! Usage of user levels is deprecated. Use capabilities instead.
    • > GET request to /wp-admin/tools.php?page=custom_permalinks
    • > Notice in wp-content/plugins/enhanced-custom-permalinks/enh-custom-permalinks.php+138
    Undefined index: fp
    • > GET request to /wp-admin/tools.php?page=custom_permalinks
    • > Notice in wp-content/plugins/enhanced-custom-permalinks/enh-custom-permalinks.php+144
    Undefined index: preview_id
    • > GET request to /wp-admin/tools.php?page=custom_permalinks
    • > Notice in wp-content/plugins/enhanced-custom-permalinks/enh-custom-permalinks.php+734
    Undefined variable: multiPermalinkSet

SRP 50% from 2 tests

🔹 Tests weight: 20 | A shallow check of the single-responsibility principle; PHP files should perform no action - including output of placeholder text - and trigger no errors when accessed directly
Almost there! Just fix the following items
  • 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/enhanced-custom-permalinks/enh-custom-permalinks.php:511

User-side errors Passed 1 test

🔹 Test weight: 20 | A shallow check that no browser errors were triggered
Everything seems fine, but this is not an exhaustive test

Optimizations

Plugin configuration 96% from 29 tests

readme.txt Passed 16 tests

The readme.txt file uses markdown syntax to describe your plugin to the world
6 plugin tags: permalink, redirect, link, custom, url...

enhanced-custom-permalinks/enh-custom-permalinks.php 92% from 13 tests

"Enhanced Custom Permalinks" version 0.1.1's main PHP file describes plugin functionality and also serves as the entry point to any WordPress functionality
You should first fix the following items:
  • Main file name: Please rename the main PHP file in this plugin to the plugin slug ("enhanced-custom-permalinks.php" instead of "enh-custom-permalinks.php")

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
Good job! No executable or dangerous file extensions detected597 lines of code in 2 files:
LanguageFilesBlank linesComment linesLines of code
PHP2168229597

PHP code Passed 2 tests

This is a very shot review of cyclomatic complexity and code structure
This plugin has no cyclomatic complexity issues
Cyclomatic complexity
Average complexity per logical line of code0.42
Average class complexity2.00
▷ Minimum class complexity2.00
▷ Maximum class complexity2.00
Average method complexity1.33
▷ Minimum method complexity1.00
▷ Maximum method complexity2.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes1
▷ Abstract classes00.00%
▷ Concrete classes1100.00%
▷ Final classes00.00%
Methods3
▷ Static methods00.00%
▷ Public methods3100.00%
▷ Protected methods00.00%
▷ Private methods00.00%
Functions30
▷ Named functions30100.00%
▷ Anonymous functions00.00%
Constants0
▷ Global constants00.00%
▷ Class constants00.00%
▷ Public constants00.00%

Plugin size Passed 2 tests

Image compression Passed 2 tests

Often times overlooked, PNG files can occupy unnecessary space in your plugin
No PNG files were detected