Benchmarks
Plugin footprint 83% from 16 tests
Installer Passed 1 test
🔺 Critical test (weight: 50) | The install procedure must perform silently
The plugin installed successfully, without throwing any errors or notices
Server metrics [RAM: ▲0.13MB] [CPU: ▼6.81ms] Passed 4 tests
Server-side resources used by picture bed base on gitee
Normal server usage
Page | Memory (MB) | CPU Time (ms) |
---|---|---|
Home / | 3.61 ▲0.15 | 43.09 ▲4.68 |
Dashboard /wp-admin | 3.45 ▲0.10 | 49.68 ▼19.22 |
Posts /wp-admin/edit.php | 3.56 ▲0.20 | 58.96 ▲1.77 |
Add New Post /wp-admin/post-new.php | 6.03 ▲0.14 | 103.68 ▼10.68 |
Media Library /wp-admin/upload.php | 3.37 ▲0.14 | 37.62 ▲0.90 |
Gitee图床 /wp-admin/options-general.php?page=picture-bed-base-on-gitee/functions.php | 3.35 | 42.94 |
Server storage [IO: ▲3.55MB] [DB: ▲0.00MB] Passed 3 tests
Filesystem and database footprint
There were no storage issued detected upon installing this plugin
Filesystem: 1,402 new files
Database: no new tables, 6 new options
New WordPress options |
---|
db_upgraded |
can_compress_scripts |
widget_recent-comments |
widget_theysaidso_widget |
theysaidso_admin_options |
widget_recent-posts |
Browser metrics Passed 4 tests
picture bed base on gitee: an overview of browser usage
There were no issues detected in relation to browser resource usage
Page | Nodes | Memory (MB) | Script (ms) | Layout (ms) |
---|---|---|---|---|
Home / | 2,835 ▲89 | 13.34 ▼1.36 | 2.02 ▲0.43 | 29.28 ▼11.20 |
Dashboard /wp-admin | 2,213 ▲31 | 5.17 ▼0.64 | 116.14 ▲12.28 | 57.09 ▲12.22 |
Posts /wp-admin/edit.php | 2,105 ▲16 | 2.26 ▲0.08 | 37.84 ▲2.03 | 48.04 ▲8.71 |
Add New Post /wp-admin/post-new.php | 1,767 ▲253 | 20.67 ▲3.19 | 692.22 ▲16.50 | 57.28 ▲3.50 |
Media Library /wp-admin/upload.php | 1,392 ▲4 | 4.35 ▲0.15 | 106.42 ▲5.66 | 53.93 ▲8.60 |
Gitee图床 /wp-admin/options-general.php?page=picture-bed-base-on-gitee/functions.php | 1,299 | 2.10 | 32.21 | 105.09 |
Uninstaller [IO: ▲0.00MB] [DB: ▲0.00MB] 75% from 4 tests
🔸 Tests weight: 35 | Checking the uninstaller removed all traces of the plugin
Please fix the following items
- The uninstall procedure has failed, leaving 6 options in the database
- widget_theysaidso_widget
- theysaidso_admin_options
- widget_recent-posts
- widget_recent-comments
- can_compress_scripts
- db_upgraded
Smoke tests 50% from 4 tests
Server-side errors 0% from 1 test
🔹 Test weight: 20 | Just a short smoke test targeting errors on the server (in the Apache logs)
Please fix the following server-side errors
- > GET request to /wp-admin/options-general.php?page=picture-bed-base-on-gitee/functions.php
- > POST request to /wp-admin/admin-ajax.php
- > Notice in wp-content/plugins/picture-bed-base-on-gitee/class/GiteeAPI.php+158
Undefined index: filters
- > GET request to /wp-admin/options-general.php?page=picture-bed-base-on-gitee/functions.php
- > POST request to /wp-admin/admin-ajax.php
- > Warning in wp-content/plugins/picture-bed-base-on-gitee/class/GiteeAPI.php+355
Invalid argument supplied for foreach()
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
The following issues need your attention
- 5× PHP files trigger server-side errors or warnings when accessed directly:
- > PHP Fatal error
Uncaught Error: Call to undefined function add_action() in wp-content/plugins/picture-bed-base-on-gitee/functions.php:92
- > PHP Fatal error
Uncaught Error: Call to undefined function wp_clear_scheduled_hook() in wp-content/plugins/picture-bed-base-on-gitee/uninstall.php:27
- > PHP Fatal error
Uncaught Error: Class 'PBBOG_Action' not found in wp-content/plugins/picture-bed-base-on-gitee/class/GiteeAPI.php:2
- > PHP Fatal error
Uncaught Error: Call to undefined function add_action() in wp-content/plugins/picture-bed-base-on-gitee/api.php:52
- > PHP Fatal error
Uncaught Error: Call to undefined function plugin_dir_path() in wp-content/plugins/picture-bed-base-on-gitee/picture-bed-base-on-gitee.php:24
- > PHP Fatal error
User-side errors Passed 1 test
🔹 Test weight: 20 | This is a shallow check for browser errors
Everything seems fine on the user side
Optimizations
Plugin configuration 93% from 29 tests
readme.txt 88% 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: These screenshots require images: #1 (imgs/screenshot-1.png), #2 (imgs/screenshot-2.png)
- Donate link: Please fix this invalid url: ""
picture-bed-base-on-gitee/picture-bed-base-on-gitee.php Passed 13 tests
The main PHP file in "picture bed base on gitee" ver. 1.0.0 adds more information about the plugin and also serves as the entry point for this plugin
89 characters long description:
picture bed base on gitee,基于Gitee的图床,可以将图片,文件上传到Gitee仓库
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
No dangerous file extensions were detected27,564 lines of code in 1,391 files:
Language | Files | Blank lines | Comment lines | Lines of code |
---|---|---|---|---|
CSS | 3 | 1,217 | 7 | 10,532 |
HTML | 3 | 14 | 10 | 5,947 |
SVG | 1,371 | 0 | 0 | 4,677 |
JavaScript | 5 | 916 | 376 | 4,028 |
JSON | 1 | 0 | 0 | 1,372 |
PHP | 8 | 47 | 92 | 1,008 |
PHP code Passed 2 tests
A brief analysis of cyclomatic complexity and code structure for this plugin
No complexity issues detected
Cyclomatic complexity | |
---|---|
Average complexity per logical line of code | 0.29 |
Average class complexity | 17.67 |
▷ Minimum class complexity | 1.00 |
▷ Maximum class complexity | 40.00 |
Average method complexity | 3.80 |
▷ Minimum method complexity | 1.00 |
▷ Maximum method complexity | 16.00 |
Code structure | ||
---|---|---|
Namespaces | 0 | |
Interfaces | 0 | |
Traits | 0 | |
Classes | 3 | |
▷ Abstract classes | 0 | 0.00% |
▷ Concrete classes | 3 | 100.00% |
▷ Final classes | 0 | 0.00% |
Methods | 16 | |
▷ Static methods | 16 | 100.00% |
▷ Public methods | 16 | 100.00% |
▷ Protected methods | 0 | 0.00% |
▷ Private methods | 0 | 0.00% |
Functions | 11 | |
▷ Named functions | 10 | 90.91% |
▷ Anonymous functions | 1 | 9.09% |
Constants | 0 | |
▷ Global constants | 0 | 0.00% |
▷ Class constants | 0 | 0.00% |
▷ Public constants | 0 | 0.00% |
Plugin size 50% from 2 tests
Image compression 50% from 2 tests
Often times overlooked, PNG files can occupy unnecessary space in your plugin
5 PNG files occupy 0.50MB with 0.32MB in potential savings
Potential savings
Compression of 5 random PNG files using pngquant | |||
---|---|---|---|
File | Size - original | Size - compressed | Savings |
assets/icon-128x128.png | 31.95KB | 12.90KB | ▼ 59.63% |
assets/imgs/screenshot-1.png | 79.76KB | 26.51KB | ▼ 66.76% |
assets/banner-772x250.png | 246.77KB | 62.72KB | ▼ 74.58% |
assets/icon-256x256.png | 103.09KB | 38.68KB | ▼ 62.47% |
assets/imgs/screenshot-2.png | 53.33KB | 25.53KB | ▼ 52.13% |