Benchmarks
Plugin footprint 65% from 16 tests
Installer Passed 1 test
🔺 Critical test (weight: 50) | Verifying that this plugin installs correctly without errors
Installer ran successfully
Server metrics [RAM: ▲0.36MB] [CPU: ▲0.76ms] Passed 4 tests
A check of server-side resources used by Referrer Analytics
This plugin has minimal impact on server resources
Page | Memory (MB) | CPU Time (ms) |
---|---|---|
Home / | 3.82 ▲0.35 | 34.46 ▼6.71 |
Dashboard /wp-admin | 3.68 ▲0.37 | 47.90 ▼5.28 |
Posts /wp-admin/edit.php | 3.79 ▲0.43 | 60.23 ▲14.62 |
Add New Post /wp-admin/post-new.php | 6.26 ▲0.36 | 105.02 ▲14.36 |
Media Library /wp-admin/upload.php | 3.60 ▲0.36 | 36.14 ▲0.67 |
Referrer Analytics /wp-admin/options-general.php?page=referrer-analytics-settings | 3.57 | 31.29 |
Server storage [IO: ▲0.32MB] [DB: ▲0.00MB] Passed 3 tests
Analyzing filesystem and database footprints of this plugin
There were no storage issued detected upon installing this plugin
Filesystem: 15 new files
Database: 1 new table, 7 new options
New tables |
---|
wp_referrer_analytics |
New WordPress options |
---|
referrer_analytics_db_version |
widget_theysaidso_widget |
widget_recent-posts |
theysaidso_admin_options |
db_upgraded |
widget_recent-comments |
can_compress_scripts |
Browser metrics Passed 4 tests
Checking browser requirements for Referrer Analytics
This plugin has a minimal impact on browser resources
Page | Nodes | Memory (MB) | Script (ms) | Layout (ms) |
---|---|---|---|---|
Home / | 2,804 ▲47 | 13.40 ▼0.78 | 1.61 ▼0.62 | 37.02 ▼14.09 |
Dashboard /wp-admin | 2,210 ▲24 | 4.84 ▼0.10 | 106.58 ▼14.35 | 41.00 ▼4.45 |
Posts /wp-admin/edit.php | 2,093 ▲4 | 1.97 ▼0.08 | 46.83 ▲10.12 | 35.39 ▲3.55 |
Add New Post /wp-admin/post-new.php | 1,545 ▲26 | 18.06 ▼5.07 | 657.55 ▼9.25 | 57.82 ▼0.30 |
Media Library /wp-admin/upload.php | 1,395 ▲10 | 4.19 ▲0.00 | 96.77 ▼3.37 | 41.67 ▼0.83 |
Referrer Analytics /wp-admin/options-general.php?page=referrer-analytics-settings | 1,172 | 2.38 | 34.59 | 46.04 |
Uninstaller [IO: ▲0.00MB] [DB: ▲0.00MB] 50% 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
- The uninstall procedure failed, leaving 1 table in the database
- wp_referrer_analytics
- Zombie WordPress options were found after uninstall: 7 options
- db_upgraded
- referrer_analytics_db_version
- can_compress_scripts
- widget_recent-comments
- widget_recent-posts
- theysaidso_admin_options
- widget_theysaidso_widget
Smoke tests 75% from 4 tests
Server-side errors Passed 1 test
🔹 Test weight: 20 | Just a short smoke test targeting errors on the server (in the Apache logs)
Good news, no errors were detected
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
- 7× PHP files trigger server-side errors or warnings when accessed directly:
- > PHP Warning
Invalid argument supplied for foreach() in wp-content/plugins/referrer-analytics/templates/unknowns.php on line 9
- > PHP Fatal error
Uncaught Error: Using $this when not in object context in wp-content/plugins/referrer-analytics/templates/line-chart.php:8
- > PHP Fatal error
Uncaught Error: Call to undefined function _e() in wp-content/plugins/referrer-analytics/templates/callout.php:3
- > PHP Fatal error
Uncaught Error: Call to undefined function esc_html_e() in wp-content/plugins/referrer-analytics/templates/unknowns.php:24
- > PHP Fatal error
Uncaught Error: Using $this when not in object context in wp-content/plugins/referrer-analytics/templates/popular-list.php:8
- > PHP Notice
Undefined variable: log in wp-content/plugins/referrer-analytics/templates/unknowns.php on line 9
- > PHP Fatal error
Uncaught Error: Using $this when not in object context in wp-content/plugins/referrer-analytics/templates/pie-chart.php:8
- > PHP Warning
User-side errors Passed 1 test
🔹 Test weight: 20 | Just a short smoke test targeting errors on the browser (console and network errors and warnings)
Everything seems fine on the user side
Optimizations
Plugin configuration 90% from 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
6 plugin tags: google analytics add-on, statistics, analytics, referrer, stats...
referrer-analytics/referrer-analytics.php 77% from 13 tests
This is the main PHP file of "Referrer Analytics" version 2.0.1, providing information about the plugin in the header fields and serving as the principal entry point to the plugin's functions
You should first fix the following items:
- Text Domain: Since WordPress version 4.6 the text domain is optional; if specified, it must be the same as the plugin slug
- Description: Please don't use more than 140 characters for the plugin description (currently 182 characters long)
- Requires PHP: The required version number must match the one declared in readme.txt ("7.1" instead of "7.2")
Code Analysis Passed 3 tests
File types Passed 1 test
🔸 Test weight: 35 | A short review of files and their extensions; it is not recommended to include executable files
Success! There were no dangerous files found in this plugin2,964 lines of code in 14 files:
Language | Files | Blank lines | Comment lines | Lines of code |
---|---|---|---|---|
PHP | 9 | 195 | 275 | 2,799 |
CSS | 2 | 31 | 0 | 147 |
JavaScript | 3 | 2 | 14 | 18 |
PHP code Passed 2 tests
This is a short overview of cyclomatic complexity and code structure for this plugin
No cyclomatic complexity issues were detected for this plugin
Cyclomatic complexity | |
---|---|
Average complexity per logical line of code | 0.46 |
Average class complexity | 91.00 |
▷ Minimum class complexity | 28.00 |
▷ Maximum class complexity | 154.00 |
Average method complexity | 5.32 |
▷ Minimum method complexity | 1.00 |
▷ Maximum method complexity | 18.00 |
Code structure | ||
---|---|---|
Namespaces | 0 | |
Interfaces | 0 | |
Traits | 0 | |
Classes | 2 | |
▷ Abstract classes | 0 | 0.00% |
▷ Concrete classes | 2 | 100.00% |
▷ Final classes | 0 | 0.00% |
Methods | 39 | |
▷ Static methods | 0 | 0.00% |
▷ Public methods | 39 | 100.00% |
▷ Protected methods | 0 | 0.00% |
▷ Private methods | 0 | 0.00% |
Functions | 2 | |
▷ Named functions | 1 | 50.00% |
▷ Anonymous functions | 1 | 50.00% |
Constants | 4 | |
▷ Global constants | 4 | 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
There are no PNG files in this plugin