89% wp-autotrack

Code Review | WP Autotrack Google Analytics

WordPress plugin WP Autotrack Google Analytics scored89%from 54 tests.

About plugin

  • Plugin page: wp-autotrack
  • Plugin version: 0.0.1
  • PHP version: 7.4.16
  • WordPress compatibility: 4.6-4.6
  • WordPress version: 6.3.1
  • First release: Sep 6, 2016
  • Latest release: Sep 6, 2016
  • Number of updates: 6
  • Update frequency: every 0.3 days
  • Top authors: watzak (100%)

Code review

54 tests

User reviews

1 review

Install metrics

20+ active /1,142 total downloads

Benchmarks

Plugin footprint 83% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | Verifying that this plugin installs correctly without errors
Install script ran successfully

Server metrics [RAM: ▲0.02MB] [CPU: ▼7.96ms] Passed 4 tests

Server-side resources used by WP Autotrack Google Analytics
This plugin has minimal impact on server resources
PageMemory (MB)CPU Time (ms)
Home /3.49 ▲0.0344.03 ▲1.37
Dashboard /wp-admin3.33 ▼0.0151.80 ▼13.00
Posts /wp-admin/edit.php3.38 ▲0.0352.07 ▲1.64
Add New Post /wp-admin/post-new.php5.91 ▲0.0380.27 ▼21.84
Media Library /wp-admin/upload.php3.26 ▲0.0341.49 ▲6.51

Server storage [IO: ▲0.46MB] [DB: ▲0.00MB] Passed 3 tests

Filesystem and database footprint
There were no storage issued detected upon installing this plugin
Filesystem: 7 new files
Database: no new tables, 6 new options
New WordPress options
can_compress_scripts
widget_recent-posts
db_upgraded
widget_theysaidso_widget
theysaidso_admin_options
widget_recent-comments

Browser metrics Passed 4 tests

This is an overview of browser requirements for WP Autotrack Google Analytics
Minimal impact on browser resources
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,836 ▲6513.77 ▼0.4124.07 ▲22.0839.22 ▼12.01
Dashboard /wp-admin2,233 ▲305.84 ▼0.0799.44 ▼9.3837.28 ▼5.89
Posts /wp-admin/edit.php2,109 ▲61.98 ▼0.0136.24 ▼5.8832.87 ▼6.34
Add New Post /wp-admin/post-new.php1,555 ▲1023.40 ▲0.36641.28 ▼25.5950.65 ▼15.66
Media Library /wp-admin/upload.php1,412 ▲94.18 ▼0.02117.70 ▲8.2249.12 ▲1.35

Uninstaller [IO: ▲0.00MB] [DB: ▲0.00MB] 75% from 4 tests

🔸 Tests weight: 35 | Checking the uninstaller removed all traces of the plugin
It is recommended to fix the following
  • This plugin did not uninstall successfully, leaving 6 options in the database
    • widget_recent-posts
    • widget_theysaidso_widget
    • db_upgraded
    • widget_recent-comments
    • theysaidso_admin_options
    • can_compress_scripts

Smoke tests Passed 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | A shallow check that no server-side errors were triggered
Even though everything seems fine, this is not an exhaustive test

SRP Passed 2 tests

🔹 Tests weight: 20 | The single-responsibility principle: PHP files have to remain inert when accessed directly, throwing no errors and performing no actions
Looking good! No server-side errors or output on direct access of PHP files

User-side errors Passed 1 test

🔹 Test weight: 20 | This is a shallow check for browser errors
No browser issues were found

Optimizations

Plugin configuration 93% from 29 tests

readme.txt 94% from 16 tests

The readme.txt file is undoubtedly the most important file in your plugin, preparing it for public listing on WordPress.org
Please fix the following attributes:
  • Tags: You are using too many tags: 63 tag instead of maximum 10
You can take inspiration from this readme.txt

wp-autotrack/wp-autotrack.php 92% from 13 tests

"WP Autotrack Google Analytics" version 0.0.1's main PHP file describes plugin functionality and also serves as the entry point to any WordPress functionality
Please make the necessary changes and fix the following:
  • Description: Please keep the plugin description shorter than 140 characters (currently 167 characters long)

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | A short check of programming languages and file extensions; no executable files are allowed
Good job! No executable or dangerous file extensions detected131 lines of code in 3 files:
LanguageFilesBlank linesComment linesLines of code
PHP23210130
JavaScript11181

PHP code Passed 2 tests

A short review of cyclomatic complexity and code structure
Everything seems fine, there were no complexity issues found
Cyclomatic complexity
Average complexity per logical line of code0.14
Average class complexity6.00
▷ Minimum class complexity6.00
▷ Maximum class complexity6.00
Average method complexity1.71
▷ Minimum method complexity1.00
▷ Maximum method complexity6.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes1
▷ Abstract classes00.00%
▷ Concrete classes1100.00%
▷ Final classes00.00%
Methods7
▷ Static methods00.00%
▷ Public methods7100.00%
▷ Protected methods00.00%
▷ Private methods00.00%
Functions0
▷ Named functions00.00%
▷ Anonymous functions00.00%
Constants0
▷ Global constants00.00%
▷ Class constants00.00%
▷ Public constants00.00%

Plugin size Passed 2 tests

Image compression Passed 2 tests

Using a strong compression for your PNG files is a great way to speed-up your plugin
1 PNG file occupies 0.29MB with 0.21MB in potential savings
Potential savings
Compression of 1 random PNG file using pngquant
FileSize - originalSize - compressedSavings
screenshot.png301.35KB84.61KB▼ 71.92%