90% rewrite-flush-button

Code Review | Rewrite Flush Button

WordPress plugin Rewrite Flush Button scored90%from 54 tests.

About plugin

  • Plugin page: rewrite-flush-button
  • Plugin version: 1.0
  • PHP version: 7.4.16
  • WordPress compatibility: 3.1-3.5.1
  • WordPress version: 6.3.1
  • First release: Jun 9, 2013
  • Latest release: Jun 10, 2013
  • Number of updates: 4
  • Update frequency: every 0.3 days
  • Top authors: sscovil (100%)

Code review

54 tests

User reviews

2 reviews

Install metrics

200+ active /4,062 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
Installer ran successfully

Server metrics [RAM: ▲0.00MB] [CPU: ▼6.31ms] Passed 4 tests

A check of server-side resources used by Rewrite Flush Button
This plugin has minimal impact on server resources
PageMemory (MB)CPU Time (ms)
Home /3.46 ▲0.0040.08 ▲0.01
Dashboard /wp-admin3.31 ▲0.0044.29 ▼3.72
Posts /wp-admin/edit.php3.36 ▲0.0048.84 ▼0.95
Add New Post /wp-admin/post-new.php5.89 ▲0.0082.20 ▼18.66
Media Library /wp-admin/upload.php3.23 ▲0.0033.94 ▼1.89

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: 4 new files
Database: no new tables, 6 new options
New WordPress options
widget_recent-comments
db_upgraded
widget_theysaidso_widget
widget_recent-posts
theysaidso_admin_options
can_compress_scripts

Browser metrics Passed 4 tests

This is an overview of browser requirements for Rewrite Flush Button
Minimal impact on browser resources
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,800 ▲4313.27 ▼1.101.82 ▼0.1040.85 ▼3.16
Dashboard /wp-admin2,206 ▲185.82 ▼0.0398.85 ▼4.2738.86 ▼1.57
Posts /wp-admin/edit.php2,092 ▲32.02 ▼0.0239.66 ▲0.3335.43 ▲0.15
Add New Post /wp-admin/post-new.php1,520 ▲623.43 ▼0.07658.14 ▲57.0251.20 ▲0.62
Media Library /wp-admin/upload.php1,382 ▼34.23 ▼0.0096.63 ▼5.8843.44 ▲0.98

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
    • db_upgraded
    • widget_recent-comments
    • widget_recent-posts
    • widget_theysaidso_widget
    • can_compress_scripts
    • theysaidso_admin_options

Smoke tests Passed 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | A smoke test targeting server-side errors
Everything seems fine, however this is by no means an exhaustive test

SRP Passed 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
No output text or server-side errors detected on direct access of PHP files

User-side errors Passed 1 test

🔹 Test weight: 20 | A shallow check that no browser errors were triggered
There were no browser issues found

Optimizations

Plugin configuration Passed 29 tests

readme.txt Passed 16 tests

The readme.txt file describes your plugin functionality and requirements and it is parsed to prepare the your plugin's listing
5 plugin tags: permalink, admin, troubleshooting, flush, rewrite

rewrite-flush-button/rewrite-flush-button.php Passed 13 tests

This is the main PHP file of "Rewrite Flush Button" version 1.0, providing information about the plugin in the header fields and serving as the principal entry point to the plugin's functions
72 characters long description:
Adds a 'Flush Rewrite Rules' button to WP-Admin > Settings > Permalinks.

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | Executable files are considered dangerous and should not be included with any WordPress plugin
There were no executable files found in this plugin107 lines of code in 2 files:
LanguageFilesBlank linesComment linesLines of code
PHP1155385
JavaScript19322

PHP code Passed 2 tests

A short review of cyclomatic complexity and code structure
No cyclomatic complexity issues were detected for this plugin
Cyclomatic complexity
Average complexity per logical line of code0.21
Average class complexity3.00
▷ Minimum class complexity3.00
▷ Maximum class complexity3.00
Average method complexity1.25
▷ Minimum method complexity1.00
▷ Maximum method complexity2.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes1
▷ Abstract classes00.00%
▷ Concrete classes1100.00%
▷ Final classes00.00%
Methods8
▷ Static methods112.50%
▷ Public methods787.50%
▷ Protected methods112.50%
▷ Private methods00.00%
Functions0
▷ Named functions00.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