89% easy-analytics-for-google

Code Review | Easy Analytics for WordPress

WordPress plugin Easy Analytics for WordPress scored89%from 54 tests.

About plugin

  • Plugin page: easy-analytics-fo...
  • Plugin version: 1.1
  • PHP version: 7.4.16
  • WordPress compatibility: 4.1-5.4
  • WordPress version: 6.3.1
  • First release: Oct 21, 2019
  • Latest release: Apr 19, 2020
  • Number of updates: 5
  • Update frequency: every 36.4 days
  • Top authors: neeraj3333 (100%)

Code review

54 tests

User reviews

1 review

Install metrics

10+ active /627 total downloads

Benchmarks

Plugin footprint 83% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | All plugins must install correctly, without throwing any errors, warnings, or notices
This plugin's installer ran successfully

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

Analyzing server-side resources used by Easy Analytics for WordPress
Normal server usage
PageMemory (MB)CPU Time (ms)
Home /3.48 ▲0.0140.54 ▲2.09
Dashboard /wp-admin3.32 ▲0.0248.08 ▼5.61
Posts /wp-admin/edit.php3.37 ▲0.0249.36 ▼2.23
Add New Post /wp-admin/post-new.php5.90 ▲0.0293.11 ▼1.71
Media Library /wp-admin/upload.php3.24 ▲0.0238.80 ▲2.56

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

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

Browser metrics Passed 4 tests

This is an overview of browser requirements for Easy Analytics for WordPress
Normal browser usage
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,831 ▲7014.90 ▲0.657.69 ▲6.2140.30 ▼2.91
Dashboard /wp-admin2,204 ▲245.57 ▼0.0991.76 ▼6.2344.36 ▲6.72
Posts /wp-admin/edit.php2,115 ▲121.99 ▲0.0340.47 ▼1.5635.70 ▼5.52
Add New Post /wp-admin/post-new.php1,538 ▲1023.28 ▲0.08672.90 ▼28.2854.07 ▼8.23
Media Library /wp-admin/upload.php1,409 ▲64.14 ▼0.06112.75 ▲3.8852.76 ▲7.24

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

🔸 Tests weight: 35 | It is important to correctly uninstall your plugin, without leaving any traces
Please fix the following items
  • This plugin does not fully uninstall, leaving 6 options in the database
    • can_compress_scripts
    • widget_recent-comments
    • widget_theysaidso_widget
    • widget_recent-posts
    • db_upgraded
    • theysaidso_admin_options

Smoke tests Passed 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | This is a shallow check for server-side errors
The smoke test was a success, however most plugin functionality was not tested

SRP Passed 2 tests

🔹 Tests weight: 20 | It is important to ensure that your PHP files perform no action when accessed directly, respecting the single-responsibility principle
No output text or server-side errors detected 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
Everything seems fine, but this is not an exhaustive test

Optimizations

Plugin configuration 90% from 29 tests

readme.txt 94% from 16 tests

The readme.txt file is an important file in your plugin as it is parsed by WordPress.org to prepare the public listing of your plugin
Please fix the following attributes:
  • Contributors: The plugin contributors field is missing
The official readme.txt might help

easy-analytics-for-google/ecs-google-analytics.php 85% from 13 tests

The entry point to "Easy Analytics for WordPress" version 1.1 is a PHP file that has certain tags in its header comment area
The following require your attention:
  • Main file name: Name the main plugin file the same as the plugin slug ("easy-analytics-for-google.php" instead of "ecs-google-analytics.php")
  • Description: Please don't use more than 140 characters for the plugin description (currently 211 characters long)

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | This is an overview of programming languages used in this plugin; dangerous file extensions are not allowed
Success! There were no dangerous files found in this plugin104 lines of code in 3 files:
LanguageFilesBlank linesComment linesLines of code
PHP33829104

PHP code Passed 2 tests

Analyzing logical lines of code, cyclomatic complexity, and other code metrics
All good! No complexity issues found
Cyclomatic complexity
Average complexity per logical line of code0.44
Average class complexity2.00
▷ Minimum class complexity2.00
▷ Maximum class complexity2.00
Average method complexity1.14
▷ Minimum method complexity1.00
▷ Maximum method complexity2.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes1
▷ Abstract classes00.00%
▷ Concrete classes1100.00%
▷ Final classes00.00%
Methods7
▷ Static methods114.29%
▷ 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

All PNG images should be compressed to minimize bandwidth usage for end users
No PNG images were found in this plugin