Benchmarks
Plugin footprint 58% from 16 tests
Installer 0% from 1 test
🔺 Critical test (weight: 50) | Verifying that this plugin installs correctly without errors
It is recommended to fix the following installer errors
- Install procedure validation failed for this plugin
- > Warning in wp-content/plugins/a-synchronization/includes/setting.php+20
Use of undefined constant AWECHAT_PLUGIN_OPTIONNAME - assumed 'AWECHAT_PLUGIN_OPTIONNAME' (this will throw an Error in a future version of PHP)
Server metrics [RAM: ▼0.70MB] [CPU: ▼20.15ms] Passed 4 tests
A check of server-side resources used by A Synchronization
Normal server usage
Page | Memory (MB) | CPU Time (ms) |
---|---|---|
Home / | 3.48 ▲0.03 | 37.50 ▼9.07 |
Dashboard /wp-admin | 3.33 ▲0.03 | 46.27 ▼7.33 |
Posts /wp-admin/edit.php | 3.30 ▼0.06 | 42.77 ▼2.73 |
Add New Post /wp-admin/post-new.php | 3.11 ▼2.77 | 36.42 ▼60.87 |
Media Library /wp-admin/upload.php | 3.25 ▲0.02 | 33.11 ▼3.32 |
Async Settings /wp-admin/options-general.php?page=Async_setting | 3.19 | 29.17 |
Server storage [IO: ▲1.03MB] [DB: ▲0.00MB] Passed 3 tests
Analyzing filesystem and database footprints of this plugin
No storage issues were detected
Filesystem: 66 new files
Database: no new tables, 7 new options
New WordPress options |
---|
can_compress_scripts |
widget_recent-posts |
widget_theysaidso_widget |
db_upgraded |
Async_setting |
theysaidso_admin_options |
widget_recent-comments |
Browser metrics Passed 4 tests
Checking browser requirements for A Synchronization
Normal browser usage
Page | Nodes | Memory (MB) | Script (ms) | Layout (ms) |
---|---|---|---|---|
Home / | 2,804 ▲69 | 13.36 ▼1.20 | 4.37 ▲2.50 | 39.97 ▼4.53 |
Dashboard /wp-admin | 2,207 ▲19 | 5.79 ▲0.89 | 96.50 ▼2.81 | 40.32 ▼1.90 |
Posts /wp-admin/edit.php | 2,103 ▲14 | 1.99 ▲0.00 | 40.66 ▲3.76 | 35.78 ▲5.30 |
Add New Post /wp-admin/post-new.php | 6,242 ▲4,728 | 25.89 ▲8.40 | 800.25 ▲110.69 | 54.62 ▼8.27 |
Media Library /wp-admin/upload.php | 1,392 ▲10 | 4.25 ▼0.03 | 94.00 ▼5.62 | 39.99 ▼7.75 |
Async Settings /wp-admin/options-general.php?page=Async_setting | 1,102 | 3.03 | 42.40 | 65.23 |
Uninstaller [IO: ▲0.00MB] [DB: ▲0.00MB] 75% from 4 tests
🔸 Tests weight: 35 | Checking the uninstaller removed all traces of the plugin
The following items require your attention
- This plugin does not fully uninstall, leaving 7 options in the database
- can_compress_scripts
- db_upgraded
- widget_recent-comments
- theysaidso_admin_options
- Async_setting
- widget_recent-posts
- widget_theysaidso_widget
Smoke tests 50% from 4 tests
Server-side errors 0% from 1 test
🔹 Test weight: 20 | A smoke test targeting server-side errors
Smoke test failed, please fix the following
- > GET request to /wp-admin/options-general.php?page=Async_setting
- > Notice in wp-content/plugins/a-synchronization/includes/setting.php+51
Undefined index: token
- 3 occurences, only the last one shown
- > GET request to /wp-admin/options-general.php?page=Async_setting
- > Notice in wp-content/plugins/a-synchronization/includes/setting.php+92
Undefined index: ximalaya
- 3 occurences, only the last one shown
- > GET request to /wp-admin/options-general.php?page=Async_setting
- > Notice in wp-content/plugins/a-synchronization/includes/setting.php+92
Trying to access array offset on value of type null
- > GET request to /wp-admin/options-general.php?page=Async_setting
- > Notice in wp-content/plugins/a-synchronization/includes/setting.php+105
Undefined index: xmlrpc_sync_ximalaya
- > GET request to /wp-admin/options-general.php?page=Async_setting
- > Notice in wp-content/plugins/a-synchronization/includes/setting.php+121
Undefined index: title_prefix
SRP 50% from 2 tests
🔹 Tests weight: 20 | SRP (Single-Responsibility Principle) - PHP files must act as libraries and never output text or perform any action when accessed directly in a browser
Please fix the following items
- 15× PHP files trigger server errors when accessed directly (only 10 are shown):
- > PHP Fatal error
Uncaught Error: Class 'PHPUnit\\Framework\\TestCase' not found in wp-content/plugins/a-synchronization/vendor/paquettg/string-encode/tests/EncodeTest.php:7
- > PHP Fatal error
Uncaught Error: Class 'PHPHtmlParser\\Dom\\AbstractNode' not found in wp-content/plugins/a-synchronization/vendor/ee01/php-html-parser/src/PHPHtmlParser/Dom/ArrayNode.php:12
- > PHP Fatal error
Uncaught Error: Class 'PHPHtmlParser\\Dom\\ArrayNode' not found in wp-content/plugins/a-synchronization/vendor/ee01/php-html-parser/src/PHPHtmlParser/Dom/InnerNode.php:13
- > PHP Fatal error
require_once(): Failed opening required 'ASYNC_PLUGIN_DIRvendor/autoload.php' (include_path='.:/usr/share/php') in wp-content/plugins/a-synchronization/includes/sync_ximalaya.php on line 5
- > PHP Fatal error
Uncaught Error: Class 'PHPHtmlParser\\Dom\\InnerNode' not found in wp-content/plugins/a-synchronization/vendor/ee01/php-html-parser/src/PHPHtmlParser/Dom/MockNode.php:11
- > PHP Warning
require_once(ASYNC_PLUGIN_DIRvendor/autoload.php): failed to open stream: No such file or directory in wp-content/plugins/a-synchronization/includes/sync_ximalaya.php on line 5
- > PHP Warning
Use of undefined constant ASYNC_PLUGIN_DIR - assumed 'ASYNC_PLUGIN_DIR' (this will throw an Error in a future version of PHP) in wp-content/plugins/a-synchronization/includes/sync_ximalaya.php on line 5
- > PHP Fatal error
Uncaught Error: Class 'PHPHtmlParser\\Dom\\LeafNode' not found in wp-content/plugins/a-synchronization/vendor/ee01/php-html-parser/src/PHPHtmlParser/Dom/TextNode.php:9
- > PHP Fatal error
Uncaught Error: Call to undefined function Async\\plugins_url() in wp-content/plugins/a-synchronization/Async.php:15
- > PHP Fatal error
require(): Failed opening required 'wp-content/plugins/a-synchronization/vendor/paquettg/string-encode/vendor/autoload.php' (include_path='.:/usr/share/php') in wp-content/plugins/a-synchronization/vendor/paquettg/string-encode/phpunit.php on line 15
- > PHP Fatal error
User-side errors Passed 1 test
🔹 Test weight: 20 | This is a shallow check for browser errors
There were no browser issues found
Optimizations
Plugin configuration 96% from 29 tests
readme.txt Passed 16 tests
Often overlooked, readme.txt is one of the most important files in your plugin
5 plugin tags: wechat, sync, connect, ximalaya, distribute
a-synchronization/Async.php 92% from 13 tests
This is the main PHP file of "A Synchronization" version 1.1, providing information about the plugin in the header fields and serving as the principal entry point to the plugin's functions
Please take the time to fix the following:
- Main file name: It is recommended to name the main PHP file as the plugin slug ("a-synchronization.php" instead of "Async.php")
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
No dangerous file extensions were detected3,343 lines of code in 54 files:
Language | Files | Blank lines | Comment lines | Lines of code |
---|---|---|---|---|
PHP | 43 | 633 | 1,725 | 2,939 |
JSON | 4 | 0 | 0 | 174 |
PO File | 1 | 31 | 32 | 84 |
YAML | 2 | 4 | 0 | 51 |
JavaScript | 1 | 7 | 4 | 39 |
Markdown | 2 | 18 | 0 | 31 |
XML | 1 | 1 | 0 | 25 |
PHP code Passed 2 tests
This is a very shot review of cyclomatic complexity and code structure
No complexity issues detected
Cyclomatic complexity | |
---|---|
Average complexity per logical line of code | 0.34 |
Average class complexity | 11.14 |
▷ Minimum class complexity | 1.00 |
▷ Maximum class complexity | 55.00 |
Average method complexity | 2.67 |
▷ Minimum method complexity | 1.00 |
▷ Maximum method complexity | 27.00 |
Code structure | ||
---|---|---|
Namespaces | 8 | |
Interfaces | 3 | |
Traits | 0 | |
Classes | 34 | |
▷ Abstract classes | 4 | 11.76% |
▷ Concrete classes | 30 | 88.24% |
▷ Final classes | 8 | 26.67% |
Methods | 234 | |
▷ Static methods | 11 | 4.70% |
▷ Public methods | 193 | 82.48% |
▷ Protected methods | 19 | 8.12% |
▷ Private methods | 22 | 9.40% |
Functions | 7 | |
▷ Named functions | 6 | 85.71% |
▷ Anonymous functions | 1 | 14.29% |
Constants | 7 | |
▷ Global constants | 6 | 85.71% |
▷ Class constants | 1 | 14.29% |
▷ Public constants | 1 | 100.00% |
Plugin size 50% from 2 tests
Image compression 50% from 2 tests
Using a strong compression for your PNG files is a great way to speed-up your plugin
5 PNG files occupy 0.84MB with 0.58MB in potential savings
Potential savings
Compression of 5 random PNG files using pngquant | |||
---|---|---|---|
File | Size - original | Size - compressed | Savings |
assets/screenshot-1.png | 196.60KB | 59.04KB | ▼ 69.97% |
assets/ximalaya_icon.png | 116.83KB | 50.17KB | ▼ 57.06% |
assets/default_acticle_image.png | 187.27KB | 51.39KB | ▼ 72.56% |
assets/screenshot-2.png | 117.60KB | 32.94KB | ▼ 71.99% |
assets/screenshot-3.png | 242.51KB | 69.35KB | ▼ 71.40% |