Benchmarks
Plugin footprint 65% from 16 tests
Installer Passed 1 test
🔺 Critical test (weight: 50) | Checking the installer triggered no errors
The plugin installed gracefully, with no errors
Server metrics [RAM: ▼8.52MB] [CPU: ▼1,771,314.53ms] Passed 4 tests
This is a short check of server-side resources used by WP Upload Restriction
No issues were detected with server-side resource usage
Page | Memory (MB) | CPU Time (ms) |
---|---|---|
Home / | 3.64 ▼34.40 | 41.46 ▼7,085,252.22 |
Dashboard /wp-admin | 3.47 ▲0.08 | 54.49 ▼11.28 |
Posts /wp-admin/edit.php | 3.59 ▲0.18 | 56.84 ▲3.66 |
Add New Post /wp-admin/post-new.php | 6.06 ▲0.13 | 102.54 ▲1.72 |
Media Library /wp-admin/upload.php | 3.40 ▲0.12 | 43.32 ▲7.61 |
WP Upload Restriction /wp-admin/options-general.php?page=wp-upload-restriction/settings.php | 3.38 | 36.03 |
Server storage [IO: ▲0.03MB] [DB: ▲0.02MB] Passed 3 tests
Analyzing filesystem and database footprints of this plugin
The plugin installed successfully
Filesystem: 11 new files
Database: no new tables, 11 new options
New WordPress options |
---|
widget_recent-posts |
widget_theysaidso_widget |
wpur_selected_mimes_author |
can_compress_scripts |
db_upgraded |
widget_recent-comments |
wpur_selected_mimes_editor |
wpur_selected_mimes_administrator |
theysaidso_admin_options |
wpur_selected_mimes_contributor |
... |
Browser metrics Passed 4 tests
This is an overview of browser requirements for WP Upload Restriction
This plugin renders optimally with no browser resource issues detected
Page | Nodes | Memory (MB) | Script (ms) | Layout (ms) |
---|---|---|---|---|
Home / | 2,793 ▲47 | 14.67 ▲0.31 | 1.61 ▼0.26 | 41.02 ▼4.47 |
Dashboard /wp-admin | 2,196 ▲16 | 5.57 ▼0.09 | 88.18 ▼14.84 | 39.21 ▼9.12 |
Posts /wp-admin/edit.php | 2,107 ▲10 | 2.07 ▲0.08 | 40.74 ▲5.75 | 36.79 ▲2.25 |
Add New Post /wp-admin/post-new.php | 1,529 ▲3 | 23.74 ▲0.23 | 696.42 ▼33.91 | 55.21 ▼23.28 |
Media Library /wp-admin/upload.php | 1,407 ▲4 | 4.15 ▼0.02 | 97.45 ▼0.87 | 41.91 ▼0.30 |
WP Upload Restriction /wp-admin/options-general.php?page=wp-upload-restriction/settings.php | 1,753 | 1.90 | 32.72 | 34.63 |
Uninstaller [IO: ▲0.00MB] [DB: ▲0.00MB] 50% from 4 tests
🔸 Tests weight: 35 | Verifying that this plugin uninstalls completely without leaving any traces
It is recommended to fix the following
- Uninstall procedure validation failed for this plugin
- > Deprecated in wp-includes/class-wp-hook.php+310
Non-static method WPUploadRestriction::uninstall() should not be called statically
- The uninstall procedure has failed, leaving 6 options in the database
- widget_recent-posts
- widget_theysaidso_widget
- widget_recent-comments
- db_upgraded
- can_compress_scripts
- theysaidso_admin_options
Smoke tests 50% from 4 tests
Server-side errors 0% from 1 test
🔹 Test weight: 20 | A shallow check that no server-side errors were triggered
Smoke test failed, please fix the following
- 11 occurences, only the last one shown
- > GET request to /wp-admin/options-general.php?page=wp-upload-restriction/settings.php
- > Warning in wp-content/plugins/easy-age-verifier/lib/extras/wpApi.php+48
file_get_contents(): php_network_getaddresses: getaddrinfo failed: Name or service not known
- 11 occurences, only the last one shown
- > GET request to /wp-admin/options-general.php?page=wp-upload-restriction/settings.php
- > Warning in wp-content/plugins/easy-age-verifier/lib/extras/wpApi.php+48
file_get_contents(http://www.fillyourtaproom.com/wp-json/wp/v2/posts?per_page=10): failed to open stream: php_network_getaddresses: getaddrinfo failed: Name or service not known
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
Please fix the following items
- 2× PHP files output non-empty strings when accessed directly via GET requests:
- > /wp-content/plugins/wp-upload-restriction/languages/index.php
- > /wp-content/plugins/wp-upload-restriction/index.php
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
The readme.txt file describes your plugin functionality and requirements and it is parsed to prepare the your plugin's listing
3 plugin tags: upload, developer tool, media
wp-upload-restriction/wp-upload-restriction.php Passed 13 tests
The main PHP script in "WP Upload Restriction" version 2.2.8 is automatically included on every request by WordPress
80 characters long description:
This plugin allows you to control upload of files based on file types and sizes.
Code Analysis Passed 3 tests
File types Passed 1 test
🔸 Test weight: 35 | This is an overview of file extensions present in this plugin and a short test that no dangerous files are bundled with this plugin
Everything looks great! No dangerous files found in this plugin636 lines of code in 6 files:
Language | Files | Blank lines | Comment lines | Lines of code |
---|---|---|---|---|
PHP | 4 | 96 | 156 | 472 |
JavaScript | 1 | 16 | 0 | 101 |
CSS | 1 | 2 | 0 | 63 |
PHP code Passed 2 tests
Analyzing logical lines of code, cyclomatic complexity, and other code metrics
There were no cyclomatic complexity issued detected
Cyclomatic complexity | |
---|---|
Average complexity per logical line of code | 0.34 |
Average class complexity | 58.00 |
▷ Minimum class complexity | 58.00 |
▷ Maximum class complexity | 58.00 |
Average method complexity | 2.69 |
▷ Minimum method complexity | 1.00 |
▷ Maximum method complexity | 9.00 |
Code structure | ||
---|---|---|
Namespaces | 0 | |
Interfaces | 0 | |
Traits | 0 | |
Classes | 1 | |
▷ Abstract classes | 0 | 0.00% |
▷ Concrete classes | 1 | 100.00% |
▷ Final classes | 0 | 0.00% |
Methods | 31 | |
▷ Static methods | 0 | 0.00% |
▷ Public methods | 22 | 70.97% |
▷ Protected methods | 0 | 0.00% |
▷ Private methods | 9 | 29.03% |
Functions | 2 | |
▷ Named functions | 0 | 0.00% |
▷ Anonymous functions | 2 | 100.00% |
Constants | 1 | |
▷ Global constants | 1 | 100.00% |
▷ Class constants | 0 | 0.00% |
▷ Public constants | 0 | 0.00% |
Plugin size Passed 2 tests
Image compression Passed 2 tests
Often times overlooked, PNG files can occupy unnecessary space in your plugin
There were not PNG files found in your plugin