84% rewrite-endpoint-master

Code Review | Rewrite Endpoint Master

WordPress plugin Rewrite Endpoint Master scored84%from 54 tests.

About plugin

  • Plugin page: rewrite-endpoint-...
  • Plugin version: 0.1.4
  • PHP version: 7.4.16
  • WordPress compatibility: 4.3-4.4
  • WordPress version: 6.3.1
  • First release: Aug 29, 2015
  • Latest release: Dec 9, 2015
  • Number of updates: 6
  • Update frequency: every 17.3 days
  • Top authors: jim912 (100%)

Code review

54 tests

User reviews

1 review

Install metrics

10+ active /1,332 total downloads

Benchmarks

Plugin footprint 83% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | Checking the installer triggered no errors
Installer ran successfully

Server metrics [RAM: ▲0.07MB] [CPU: ▼7.25ms] Passed 4 tests

A check of server-side resources used by Rewrite Endpoint Master
No issues were detected with server-side resource usage
PageMemory (MB)CPU Time (ms)
Home /3.53 ▲0.0742.49 ▲7.38
Dashboard /wp-admin3.37 ▲0.0745.39 ▼7.53
Posts /wp-admin/edit.php3.42 ▲0.0745.23 ▼0.27
Add New Post /wp-admin/post-new.php5.95 ▲0.0779.43 ▼22.67
Media Library /wp-admin/upload.php3.30 ▲0.0735.59 ▲1.46
Endpoints /wp-admin/edit.php?post_type=endpoint-master3.3544.59

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

Analyzing filesystem and database footprints of this plugin
No storage issues were detected
Filesystem: 7 new files
Database: no new tables, 6 new options
New WordPress options
widget_recent-posts
theysaidso_admin_options
widget_recent-comments
db_upgraded
widget_theysaidso_widget
can_compress_scripts

Browser metrics Passed 4 tests

A check of browser resources used by Rewrite Endpoint Master
There were no issues detected in relation to browser resource usage
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,804 ▲5813.18 ▼1.131.76 ▲0.1842.47 ▲0.14
Dashboard /wp-admin2,213 ▲254.79 ▼1.12100.24 ▼3.4338.45 ▲0.12
Posts /wp-admin/edit.php2,090 ▲42.12 ▲0.1335.41 ▼1.5131.84 ▼1.81
Add New Post /wp-admin/post-new.php1,536 ▲823.38 ▲4.64632.69 ▲41.1953.28 ▼15.95
Media Library /wp-admin/upload.php1,395 ▲74.21 ▲0.0793.97 ▼10.0941.30 ▼2.96
Endpoints /wp-admin/edit.php?post_type=endpoint-master1,0542.0129.0029.24

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

🔸 Tests weight: 35 | Verifying that this plugin uninstalls completely without leaving any traces
Please fix the following items
  • Zombie WordPress options were found after uninstall: 6 options
    • can_compress_scripts
    • widget_recent-comments
    • widget_recent-posts
    • theysaidso_admin_options
    • db_upgraded
    • widget_theysaidso_widget

Smoke tests 75% from 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | A smoke test targeting server-side errors
Even though everything seems fine, this is not an exhaustive test

SRP 50% from 2 tests

🔹 Tests weight: 20 | It is important to ensure that your PHP files perform no action when accessed directly, respecting the single-responsibility principle
Almost there! Just fix the following items
  • 16× GET requests to PHP files trigger server-side errors or Error 500 responses (only 10 are shown):
    • > PHP Warning
      Use of undefined constant EP_MONTH - assumed 'EP_MONTH' (this will throw an Error in a future version of PHP) in wp-content/plugins/rewrite-endpoint-master/rewrite-endpoint-master.php on line 309
    • > PHP Warning
      Use of undefined constant EP_CATEGORIES - assumed 'EP_CATEGORIES' (this will throw an Error in a future version of PHP) in wp-content/plugins/rewrite-endpoint-master/rewrite-endpoint-master.php on line 309
    • > PHP Warning
      Use of undefined constant EP_TAGS - assumed 'EP_TAGS' (this will throw an Error in a future version of PHP) in wp-content/plugins/rewrite-endpoint-master/rewrite-endpoint-master.php on line 309
    • > PHP Warning
      Use of undefined constant EP_ALL - assumed 'EP_ALL' (this will throw an Error in a future version of PHP) in wp-content/plugins/rewrite-endpoint-master/rewrite-endpoint-master.php on line 309
    • > PHP Warning
      Use of undefined constant EP_PAGES - assumed 'EP_PAGES' (this will throw an Error in a future version of PHP) in wp-content/plugins/rewrite-endpoint-master/rewrite-endpoint-master.php on line 309
    • > PHP Warning
      Use of undefined constant EP_PERMALINK - assumed 'EP_PERMALINK' (this will throw an Error in a future version of PHP) in wp-content/plugins/rewrite-endpoint-master/rewrite-endpoint-master.php on line 309
    • > PHP Warning
      Use of undefined constant EP_ATTACHMENT - assumed 'EP_ATTACHMENT' (this will throw an Error in a future version of PHP) in wp-content/plugins/rewrite-endpoint-master/rewrite-endpoint-master.php on line 309
    • > PHP Warning
      Use of undefined constant EP_DATE - assumed 'EP_DATE' (this will throw an Error in a future version of PHP) in wp-content/plugins/rewrite-endpoint-master/rewrite-endpoint-master.php on line 309
    • > PHP Warning
      Use of undefined constant EP_DAY - assumed 'EP_DAY' (this will throw an Error in a future version of PHP) in wp-content/plugins/rewrite-endpoint-master/rewrite-endpoint-master.php on line 309
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_action() in wp-content/plugins/rewrite-endpoint-master/rewrite-endpoint-master.php:36

User-side errors Passed 1 test

🔹 Test weight: 20 | This is just a short smoke test looking for browser issues
No browser errors were detected

Optimizations

Plugin configuration Passed 29 tests

readme.txt Passed 16 tests

It's important to format your readme.txt file correctly as it is parsed for the public listing of your plugin
3 plugin tags: permalink, rewrite, endpoint

rewrite-endpoint-master/rewrite-endpoint-master.php Passed 13 tests

"Rewrite Endpoint Master" version 0.1.4's primary PHP file adds more information about the plugin and serves as the entry point for WordPress
61 characters long description:
This plugin manage custom rewrite endpoints from admin panel.

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | A short check of programming languages and file extensions; no executable files are allowed
There were no executable files found in this plugin300 lines of code in 3 files:
LanguageFilesBlank linesComment linesLines of code
PHP23616271
PO File17729

PHP code Passed 2 tests

A brief analysis of cyclomatic complexity and code structure for this plugin
Great job! No cyclomatic complexity issues were detected in this plugin
Cyclomatic complexity
Average complexity per logical line of code0.63
Average class complexity66.00
▷ Minimum class complexity66.00
▷ Maximum class complexity66.00
Average method complexity6.00
▷ Minimum method complexity1.00
▷ Maximum method complexity14.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes1
▷ Abstract classes00.00%
▷ Concrete classes1100.00%
▷ Final classes00.00%
Methods13
▷ Static methods17.69%
▷ Public methods1292.31%
▷ Protected methods00.00%
▷ Private methods17.69%
Functions2
▷ Named functions2100.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