78% wp-alternative-slug-by-010pixel

Code Review | WP Alternative Slug by 010Pixel

WordPress plugin WP Alternative Slug by 010Pixel scored 78% from 53 tests.

About plugin

  • Plugin page: wp-alternative-sl...
  • Plugin version: 1.3.0
  • PHP version: 7.4.16
  • WordPress compatibility: 3.1-4.9
  • WordPress version: 5.8.1
  • First release: Jan 7, 2016
  • Latest release: Aug 3, 2018
  • Number of updates: 15
  • Update frequency: every 62.6 days
  • Top authors: 010pixel (100%)

Code review

53 tests

User reviews

1 review

Install metrics

60+ active / 1,317 total downloads

Benchmarks

Plugin footprint 83% from 16 tests

Installer Passed 1 test

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

Server metrics [RAM: ▼0.34MB] [CPU: ▼267.84ms] Passed 4 tests

An overview of server-side resources used by WP Alternative Slug by 010Pixel
This plugin does not affect your website's performance
PageMemory (MB)CPU Time (ms)
Home /2.84 ▲0.0031.43 ▲5.32
Dashboard /wp-admin3.07 ▲0.0244.30 ▲1.21
Posts /wp-admin/edit.php3.12 ▲0.0247.22 ▲4.57
Add New Post /wp-admin/post-new.php4.05 ▼1.3847.43 ▼1,066.56
Media Library /wp-admin/upload.php3.01 ▲0.0128.30 ▼10.57
Alternative Slug Metabox /wp-admin/options-general.php?page=010pixel_alternative_slug2.9627.76

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

Analyzing filesystem and database footprints of this plugin
This plugin installed successfully
Filesystem: 5 new files
Database: no new tables, 1 new option
New WordPress options
alternative_slug_post_type_list

Browser metrics Passed 4 tests

This is an overview of browser requirements for WP Alternative Slug by 010Pixel
There were no issues detected in relation to browser resource usage
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /3,654 ▲4815.80 ▲0.207.18 ▼1.0448.02 ▼0.21
Dashboard /wp-admin2,935 ▲825.94 ▲0.14132.47 ▼0.56115.03 ▲24.82
Posts /wp-admin/edit.php2,711 ▲52.69 ▼0.0065.49 ▼11.6888.27 ▼9.38
Add New Post /wp-admin/post-new.php3,710 ▲2,05715.03 ▼3.72410.44 ▲41.75108.63 ▲6.03
Media Library /wp-admin/upload.php1,780 ▲115.01 ▼0.03153.76 ▼0.49107.24 ▼4.99
Alternative Slug Metabox /wp-admin/options-general.php?page=010pixel_alternative_slug1,0112.0955.4073.73

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
You still need to fix the following
  • Zombie WordPress options were found after uninstall: 1 option
    • alternative_slug_post_type_list

Smoke tests 50% from 4 tests

Server-side errors 0% from 1 test

🔹 Test weight: 20 | A smoke test targeting server-side errors
Please fix the following server-side errors
    • > GET request to /wp-admin/options-general.php?page=010pixel_alternative_slug
    • > User deprecated in wp-includes/functions.php+5221
    screen_icon is deprecated since version 3.8.0 with no alternative available.
    • > GET request to /wp-admin/options-general.php?page=010pixel_alternative_slug
    • > User deprecated in wp-includes/functions.php+5221
    get_screen_icon is deprecated since version 3.8.0 with no alternative available.

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
The following issues need your attention
  • 1× GET requests to PHP files trigger server-side errors or Error 500 responses:
    • > PHP Fatal error
      Uncaught Error: Call to undefined function is_admin() in wp-content/plugins/wp-alternative-slug-by-010pixel/010pixel-wp-alternative-slug.php:23

User-side errors Passed 1 test

🔹 Test weight: 20 | This is a shallow check for browser errors
No browser issues were found

Optimizations

Plugin configuration 90% from 29 tests

readme.txt 88% from 16 tests

The readme.txt file describes your plugin functionality and requirements and it is parsed to prepare the your plugin's listing
These attributes need your attention:
  • Tags: You are using too many tags: 11 tag instead of maximum 10
  • Screenshots: Please add images for these screenshots: #1 (Settings in WordPress to choose Custom Post Types), #2 (Sample Alternative Slug Metabox)
Please take inspiration from this readme.txt

wp-alternative-slug-by-010pixel/010pixel-wp-alternative-slug.php 92% from 13 tests

The principal PHP file in "WP Alternative Slug by 010Pixel" v. 1.3.0 is loaded by WordPress automatically on each request
Please make the necessary changes and fix the following:
  • Main file name: The principal plugin file should be the same as the plugin slug ("wp-alternative-slug-by-010pixel.php" instead of "010pixel-wp-alternative-slug.php")

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | A short glimpse at programming languages used with this plugin and a check that no dangerous files are present
Success! There were no dangerous files found in this plugin192 lines of code in 1 file:
LanguageFilesBlank linesComment linesLines of code
PHP16183192

PHP code Passed 2 tests

An short overview of logical lines of code, cyclomatic complexity, and other code metrics
All good! No complexity issues found
Cyclomatic complexity
Average complexity per logical line of code0.30
Average class complexity5.50
▷ Minimum class complexity1.00
▷ Maximum class complexity12.00
Average method complexity2.00
▷ Minimum method complexity1.00
▷ Maximum method complexity9.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes4
▷ Abstract classes00.00%
▷ Concrete classes4100.00%
▷ Final classes00.00%
Methods18
▷ Static methods15.56%
▷ Public methods1583.33%
▷ Protected methods316.67%
▷ Private methods00.00%
Functions0
▷ Named functions00.00%
▷ Anonymous functions00.00%
Constants0
▷ Global constants00.00%
▷ Class constants00.00%
▷ Public constants00.00%

Plugin size Passed 1 test

Image compression Passed 1 test

All PNG images should be compressed to minimize bandwidth usage for end users
2 PNG files occupy 0.09MB with 0.06MB in potential savings
Potential savings
Compression of 2 random PNG files using pngquant
FileSize - originalSize - compressedSavings
screenshot-2.png50.28KB13.53KB▼ 73.10%
screenshot-1.png37.39KB8.68KB▼ 76.77%