83% reset-slugs

Code Review | Reset Slugs

WordPress plugin Reset Slugs scored83%from 54 tests.

About plugin

  • Plugin page: reset-slugs
  • Plugin version: 1.2
  • PHP version: 7.4.16
  • WordPress compatibility: 3.4-3.8.1
  • WordPress version: 6.3.1
  • First release: Feb 28, 2014
  • Latest release: Feb 28, 2014
  • Number of updates: 3
  • Update frequency: every 0.3 days
  • Top authors: codearachnid (100%)

Code review

54 tests

User reviews

4 reviews

Install metrics

70+ active /2,475 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.02MB] [CPU: ▼6.41ms] Passed 4 tests

An overview of server-side resources used by Reset Slugs
This plugin has minimal impact on server resources
PageMemory (MB)CPU Time (ms)
Home /3.49 ▲0.0339.99 ▼4.32
Dashboard /wp-admin3.34 ▼0.0150.31 ▼16.14
Posts /wp-admin/edit.php3.39 ▲0.0350.42 ▲1.64
Add New Post /wp-admin/post-new.php5.92 ▲0.0391.77 ▼5.31
Media Library /wp-admin/upload.php3.26 ▲0.0337.43 ▲0.14
Reset Slugs /wp-admin/options-general.php?page=wprs_options3.2334.15

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

Analyzing filesystem and database footprints of this plugin
The plugin installed successfully
Filesystem: 5 new files
Database: no new tables, 6 new options
New WordPress options
widget_recent-comments
can_compress_scripts
theysaidso_admin_options
widget_recent-posts
db_upgraded
widget_theysaidso_widget

Browser metrics Passed 4 tests

Checking browser requirements for Reset Slugs
Minimal impact on browser resources
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,804 ▲5814.48 ▲0.071.71 ▼0.2944.00 ▼0.89
Dashboard /wp-admin2,210 ▲225.85 ▲0.96105.16 ▼11.2443.01 ▼2.97
Posts /wp-admin/edit.php2,093 ▲42.04 ▲0.0440.54 ▲3.1134.96 ▼1.66
Add New Post /wp-admin/post-new.php1,545 ▲1718.66 ▲0.44621.78 ▼15.1653.64 ▼0.54
Media Library /wp-admin/upload.php1,392 ▲14.21 ▼0.0997.49 ▼7.8143.91 ▼1.74
Reset Slugs /wp-admin/options-general.php?page=wprs_options9282.0622.6328.80

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

🔸 Tests weight: 35 | It is important to correctly uninstall your plugin, without leaving any traces
It is recommended to fix the following
  • This plugin does not fully uninstall, leaving 6 options in the database
    • widget_recent-posts
    • theysaidso_admin_options
    • db_upgraded
    • widget_theysaidso_widget
    • widget_recent-comments
    • can_compress_scripts

Smoke tests 75% from 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | This is a shallow check for server-side errors
Good news, no errors were detected

SRP 50% from 2 tests

🔹 Tests weight: 20 | The single-responsibility principle applies for WordPress plugins as well - please make sure your PHP files perform no actions when accessed directly
Please fix the following
  • 1× PHP files output text when accessed directly:
    • > /wp-content/plugins/reset-slugs/wp-reset-slug.php

User-side errors Passed 1 test

🔹 Test weight: 20 | A shallow check that no browser errors were triggered
No browser errors were detected

Optimizations

Plugin configuration 86% from 29 tests

readme.txt 94% from 16 tests

It's important to format your readme.txt file correctly as it is parsed for the public listing of your plugin
These attributes need your attention:
  • Screenshots: Screenshot #1 (Settings Page) image missing
The official readme.txt is a good inspiration

reset-slugs/wp-reset-slug.php 77% from 13 tests

"Reset Slugs" version 1.2's main PHP file describes plugin functionality and also serves as the entry point to any WordPress functionality
Please make the necessary changes and fix the following:
  • Text Domain: The text domain must be the same as the plugin slug, although optional since WordPress version 4.6
  • Main file name: Even though not officially enforced, the main plugin file should be the same as the plugin slug ("reset-slugs.php" instead of "wp-reset-slug.php")
  • Domain Path: The domain path points to a folder that does not exist ("/lang/")

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 plugin140 lines of code in 2 files:
LanguageFilesBlank linesComment linesLines of code
PHP23167140

PHP code Passed 2 tests

An short overview of logical lines of code, cyclomatic complexity, and other code metrics
Everything seems fine, there were no complexity issues found
Cyclomatic complexity
Average complexity per logical line of code0.30
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%
Functions8
▷ Named functions8100.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
1 PNG file occupies 0.04MB with 0.02MB in potential savings
Potential savings
Compression of 1 random PNG file using pngquant
FileSize - originalSize - compressedSavings
screenshot.png41.80KB16.51KB▼ 60.49%