Benchmarks
Plugin footprint 83% from 16 tests
Installer Passed 1 test
🔺 Critical test (weight: 50) | Verifying that this plugin installs correctly without errors
This plugin's installer ran successfully
Server metrics [RAM: ▲0.07MB] [CPU: ▼6.65ms] Passed 4 tests
Server-side resources used by Year Updater
No issues were detected with server-side resource usage
Page | Memory (MB) | CPU Time (ms) |
---|---|---|
Home / | 3.53 ▲0.06 | 35.24 ▼8.78 |
Dashboard /wp-admin | 3.37 ▲0.07 | 48.59 ▼6.37 |
Posts /wp-admin/edit.php | 3.49 ▲0.13 | 49.42 ▼3.64 |
Add New Post /wp-admin/post-new.php | 5.97 ▲0.09 | 89.92 ▼7.81 |
Media Library /wp-admin/upload.php | 3.30 ▲0.07 | 34.39 ▲0.67 |
Server storage [IO: ▲0.05MB] [DB: ▲0.00MB] Passed 3 tests
How much does this plugin use your filesystem and database?
This plugin was installed successfully
Filesystem: 11 new files
Database: no new tables, 6 new options
New WordPress options |
---|
widget_recent-comments |
widget_recent-posts |
theysaidso_admin_options |
can_compress_scripts |
db_upgraded |
widget_theysaidso_widget |
Browser metrics Passed 4 tests
Checking browser requirements for Year Updater
This plugin renders optimally with no browser resource issues detected
Page | Nodes | Memory (MB) | Script (ms) | Layout (ms) |
---|---|---|---|---|
Home / | 2,810 ▲23 | 14.70 ▲0.43 | 1.58 ▼0.26 | 36.16 ▼9.94 |
Dashboard /wp-admin | 2,215 ▲41 | 5.61 ▲0.01 | 92.50 ▲0.71 | 44.58 ▲2.08 |
Posts /wp-admin/edit.php | 2,120 ▲20 | 1.99 ▲0.04 | 36.16 ▼5.33 | 36.56 ▲4.01 |
Add New Post /wp-admin/post-new.php | 1,543 ▲14 | 23.44 ▲0.38 | 677.47 ▲84.21 | 52.65 ▼1.24 |
Media Library /wp-admin/upload.php | 1,420 ▲29 | 4.18 ▼0.10 | 95.78 ▼3.23 | 43.01 ▲2.81 |
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
You still need to fix the following
- This plugin does not fully uninstall, leaving 6 options in the database
- db_upgraded
- can_compress_scripts
- widget_recent-comments
- widget_recent-posts
- widget_theysaidso_widget
- theysaidso_admin_options
Smoke tests 75% from 4 tests
Server-side errors Passed 1 test
🔹 Test weight: 20 | A shallow check that no server-side errors were triggered
The smoke test was a success, however most plugin functionality was not tested
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 Warning
require_once(YU_PLUGIN_PATHincludes/yu-settings.php): failed to open stream: No such file or directory in wp-content/plugins/year-updater/yu-core.php on line 3
- > PHP Notice
Undefined index: post_type in wp-content/plugins/year-updater/includes/yu-preview.php on line 3
- > PHP Fatal error
require_once(): Failed opening required 'YU_PLUGIN_PATHincludes/yu-settings.php' (include_path='.:/usr/share/php') in wp-content/plugins/year-updater/yu-core.php on line 3
- > PHP Warning
Use of undefined constant YU_PLUGIN_PATH - assumed 'YU_PLUGIN_PATH' (this will throw an Error in a future version of PHP) in wp-content/plugins/year-updater/yu-core.php on line 3
- > PHP Fatal error
Uncaught Error: Call to undefined function get_posts() in wp-content/plugins/year-updater/includes/yu-preview.php:6
- > PHP Warning
User-side errors Passed 1 test
🔹 Test weight: 20 | This is just a short smoke test looking for browser issues
Everything seems fine on the user side
Optimizations
Plugin configuration Passed 29 tests
readme.txt Passed 16 tests
The readme.txt file is important because it is parsed by WordPress.org for the public listing of your plugin
3 plugin tags: year, updater, title
year-updater/year-updater.php Passed 13 tests
Analyzing the main PHP file in "Year Updater" version 1.3.0
90 characters long description:
This plugin allows you to update the year in the titles of your posts to the current year.
Code Analysis Passed 3 tests
File types Passed 1 test
🔸 Test weight: 35 | Executable files are not allowed as they can serve as attack vectors
No dangerous file extensions were detected358 lines of code in 9 files:
Language | Files | Blank lines | Comment lines | Lines of code |
---|---|---|---|---|
PHP | 7 | 87 | 34 | 358 |
CSS | 1 | 0 | 3 | 0 |
JavaScript | 1 | 2 | 5 | 0 |
PHP code Passed 2 tests
Analyzing logical lines of code, cyclomatic complexity, and other code metrics
Although this was not an exhaustive test, there were no cyclomatic complexity issues detected
Cyclomatic complexity | |
---|---|
Average complexity per logical line of code | 0.20 |
Average class complexity | 4.33 |
▷ Minimum class complexity | 1.00 |
▷ Maximum class complexity | 12.00 |
Average method complexity | 1.83 |
▷ Minimum method complexity | 1.00 |
▷ Maximum method complexity | 5.00 |
Code structure | ||
---|---|---|
Namespaces | 1 | |
Interfaces | 0 | |
Traits | 0 | |
Classes | 6 | |
▷ Abstract classes | 0 | 0.00% |
▷ Concrete classes | 6 | 100.00% |
▷ Final classes | 0 | 0.00% |
Methods | 26 | |
▷ Static methods | 0 | 0.00% |
▷ Public methods | 21 | 80.77% |
▷ Protected methods | 0 | 0.00% |
▷ Private methods | 5 | 19.23% |
Functions | 2 | |
▷ Named functions | 0 | 0.00% |
▷ Anonymous functions | 2 | 100.00% |
Constants | 3 | |
▷ Global constants | 3 | 100.00% |
▷ Class constants | 0 | 0.00% |
▷ Public constants | 0 | 0.00% |
Plugin size Passed 2 tests
Image compression Passed 2 tests
It is recommended to compress PNG files in your plugin to minimize bandwidth usage
PNG images were not found in this plugin