90% doubledome-google-analytics

Code Review | DoubleDome - Google Analytics Setup

WordPress plugin DoubleDome - Google Analytics Setup scored90%from 54 tests.

About plugin

  • Plugin page: doubledome-google...
  • Plugin version: 1.2
  • PHP version: 7.4.16
  • WordPress compatibility: 5.4-6.2.2
  • WordPress version: 6.3.1
  • First release: Sep 23, 2022
  • Latest release: Jul 29, 2023
  • Number of updates: 8
  • Update frequency: every 38.9 days
  • Top authors: doubledome (100%)

Code review

54 tests

User reviews

1 review

Install metrics

90+ active /829 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
Installer ran successfully

Server metrics [RAM: ▼0.00MB] [CPU: ▼11.90ms] Passed 4 tests

This is a short check of server-side resources used by DoubleDome - Google Analytics Setup
This plugin has minimal impact on server resources
PageMemory (MB)CPU Time (ms)
Home /3.47 ▲0.0037.76 ▼5.37
Dashboard /wp-admin3.31 ▼0.0347.23 ▼13.60
Posts /wp-admin/edit.php3.36 ▲0.0146.58 ▼5.25
Add New Post /wp-admin/post-new.php5.89 ▲0.0177.98 ▼23.39
Media Library /wp-admin/upload.php3.24 ▲0.0132.23 ▼2.08

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

A short overview of filesystem and database impact
The plugin installed successfully
Filesystem: 15 new files
Database: no new tables, 6 new options
New WordPress options
widget_theysaidso_widget
db_upgraded
widget_recent-posts
can_compress_scripts
widget_recent-comments
theysaidso_admin_options

Browser metrics Passed 4 tests

Checking browser requirements for DoubleDome - Google Analytics Setup
There were no issues detected in relation to browser resource usage
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,804 ▲4314.10 ▼0.461.55 ▼0.0940.93 ▲1.29
Dashboard /wp-admin2,210 ▲305.52 ▼0.0784.69 ▼3.8768.77 ▲25.29
Posts /wp-admin/edit.php2,097 ▼32.00 ▼0.0338.07 ▼2.3634.12 ▼1.64
Add New Post /wp-admin/post-new.php1,554 ▲2023.10 ▲4.59657.44 ▲65.2362.80 ▼1.53
Media Library /wp-admin/upload.php1,418 ▲214.08 ▼0.1494.66 ▼28.0080.53 ▲27.26

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
  • Zombie WordPress options detected upon uninstall: 6 options
    • theysaidso_admin_options
    • can_compress_scripts
    • widget_recent-posts
    • db_upgraded
    • widget_theysaidso_widget
    • widget_recent-comments

Smoke tests Passed 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 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 just a short smoke test looking for browser issues
There were no browser issues found

Optimizations

Plugin configuration 96% from 29 tests

readme.txt Passed 16 tests

Perhaps the most important file in your plugin readme.txt gets parsed in order to generate the public listing of your plugin
4 plugin tags: ga4, google analytics 4, ga, google analytics

doubledome-google-analytics/google-analytics-dd.php 92% from 13 tests

The main file in "DoubleDome - Google Analytics Setup" v. 1.2 serves as a complement to information provided in readme.txt and as the entry point to the plugin
Please take the time to fix the following:
  • Main file name: It is recommended to name the main PHP file as the plugin slug ("doubledome-google-analytics.php" instead of "google-analytics-dd.php")

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | There should be no dangerous file extensions present in any WordPress plugin
Success! There were no dangerous files found in this plugin329 lines of code in 5 files:
LanguageFilesBlank linesComment linesLines of code
PHP23119267
CSS12047
JavaScript10014
SVG1001

PHP code Passed 2 tests

This is a short overview of cyclomatic complexity and code structure for this plugin
Great job! No cyclomatic complexity issues were detected in this plugin
Cyclomatic complexity
Average complexity per logical line of code0.32
Average class complexity0.00
▷ Minimum class complexity0.00
▷ Maximum class complexity0.00
Average method complexity0.00
▷ Minimum method complexity0.00
▷ Maximum method complexity0.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes0
▷ Abstract classes00.00%
▷ Concrete classes00.00%
▷ Final classes00.00%
Methods0
▷ Static methods00.00%
▷ Public methods00.00%
▷ Protected methods00.00%
▷ Private methods00.00%
Functions10
▷ Named functions10100.00%
▷ Anonymous functions00.00%
Constants3
▷ Global constants3100.00%
▷ Class constants00.00%
▷ Public constants00.00%

Plugin size Passed 2 tests

Image compression Passed 2 tests

All PNG images should be compressed to minimize bandwidth usage for end users
6 PNG files occupy 0.22MB with 0.10MB in potential savings
Potential savings
Compression of 5 random PNG files using pngquant
FileSize - originalSize - compressedSavings
assets/dd-ga4-overview-icon.png5.97KB2.85KB▼ 52.21%
assets/icon-128x128.png5.97KB2.85KB▼ 52.21%
assets/doubledome.png0.52KB0.74KB0.00%
assets/icon-256x256.png13.40KB5.41KB▼ 59.62%
assets/banner-772x250.png58.01KB21.79KB▼ 62.44%