78% adroll-for-woocommerce-stores-dev

Code Review | AdRoll for WooCommerce Stores

WordPress plugin AdRoll for WooCommerce Stores scored78%from 54 tests.

About plugin

Code review

54 tests

User reviews

9 reviews

Install metrics

1,000+ active /38,786 total downloads

Benchmarks

Plugin footprint 83% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | The install procedure must perform silently
Install script ran successfully

Server metrics [RAM: ▲0.03MB] [CPU: ▼4.05ms] Passed 4 tests

This is a short check of server-side resources used by AdRoll for WooCommerce Stores
This plugin does not affect your website's performance
PageMemory (MB)CPU Time (ms)
Home /3.53 ▲0.0737.30 ▼2.70
Dashboard /wp-admin3.33 ▲0.0346.07 ▼0.67
Posts /wp-admin/edit.php3.39 ▲0.0349.52 ▲3.07
Add New Post /wp-admin/post-new.php5.92 ▲0.0385.41 ▼15.59
Media Library /wp-admin/upload.php3.26 ▲0.0334.80 ▲2.77

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

Analyzing filesystem and database footprints of this plugin
This plugin installed successfully
Filesystem: 8 new files
Database: no new tables, 6 new options
New WordPress options
widget_recent-posts
widget_recent-comments
db_upgraded
widget_theysaidso_widget
can_compress_scripts
theysaidso_admin_options

Browser metrics Passed 4 tests

An overview of browser requirements for AdRoll for WooCommerce Stores
This plugin renders optimally with no browser resource issues detected
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,834 ▲4714.71 ▲0.361.48 ▼0.1337.34 ▼1.42
Dashboard /wp-admin2,237 ▲635.60 ▲0.0790.89 ▼2.9540.04 ▼2.29
Posts /wp-admin/edit.php2,139 ▲391.98 ▲0.0340.23 ▲1.3137.18 ▼1.22
Add New Post /wp-admin/post-new.php1,550 ▲2123.32 ▲0.33624.04 ▼85.0470.42 ▲14.48
Media Library /wp-admin/upload.php1,441 ▲414.25 ▲0.0999.24 ▲0.6244.08 ▲3.10

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
It is recommended to fix the following
  • This plugin does not fully uninstall, leaving 6 options in the database
    • widget_recent-posts
    • widget_recent-comments
    • can_compress_scripts
    • widget_theysaidso_widget
    • db_upgraded
    • theysaidso_admin_options

Smoke tests 50% from 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | This is a short smoke test looking for server-side errors
Even though no errors were found, this is by no means an exhaustive test

SRP 0% from 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
Please take a closer look at the following
  • 1× PHP files perform the task of outputting text when accessed with GET requests:
    • > /wp-content/plugins/adroll-for-woocommerce-stores-dev/adroll-for-woocommerce.php
  • 5× PHP files trigger server-side errors or warnings when accessed directly:
    • > PHP Fatal error
      Uncaught Error: Using $this when not in object context in wp-content/plugins/adroll-for-woocommerce-stores-dev/pixel.php:2
    • > PHP Fatal error
      Uncaught Error: Call to undefined function settings_fields() in wp-content/plugins/adroll-for-woocommerce-stores-dev/configure.php:6
    • > PHP Fatal error
      Uncaught Error: Using $this when not in object context in wp-content/plugins/adroll-for-woocommerce-stores-dev/status.php:4
    • > PHP Fatal error
      Uncaught Error: Using $this when not in object context in wp-content/plugins/adroll-for-woocommerce-stores-dev/welcome.php:3
    • > PHP Fatal error
      Uncaught Error: Using $this when not in object context in wp-content/plugins/adroll-for-woocommerce-stores-dev/notice.php:3

User-side errors Passed 1 test

🔹 Test weight: 20 | This is a shallow check for browser errors
Everything seems fine, but this is not an exhaustive test

Optimizations

Plugin configuration 96% from 29 tests

readme.txt Passed 16 tests

The readme.txt file is undoubtedly the most important file in your plugin, preparing it for public listing on WordPress.org
10 plugin tags: display, marketing, nextroll, email, advertising...

adroll-for-woocommerce-stores-dev/adroll-for-woocommerce.php 92% from 13 tests

The primary PHP file in "AdRoll for WooCommerce Stores" version 2.3.0 is used by WordPress to initiate all plugin functionality
It is important to fix the following:
  • Main file name: Name the main plugin file the same as the plugin slug ("adroll-for-woocommerce-stores-dev.php" instead of "adroll-for-woocommerce.php")

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
There were no executable files found in this plugin482 lines of code in 7 files:
LanguageFilesBlank linesComment linesLines of code
PHP78161482

PHP code Passed 2 tests

Analyzing cyclomatic complexity and code structure
Great job! No cyclomatic complexity issues were detected in this plugin
Cyclomatic complexity
Average complexity per logical line of code0.30
Average class complexity63.00
▷ Minimum class complexity63.00
▷ Maximum class complexity63.00
Average method complexity2.53
▷ Minimum method complexity1.00
▷ Maximum method complexity16.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes1
▷ Abstract classes00.00%
▷ Concrete classes1100.00%
▷ Final classes00.00%
Methods40
▷ Static methods12.50%
▷ Public methods2050.00%
▷ Protected methods00.00%
▷ Private methods2050.00%
Functions2
▷ Named functions00.00%
▷ Anonymous functions2100.00%
Constants2
▷ Global constants00.00%
▷ Class constants2100.00%
▷ Public constants2100.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
There are no PNG files in this plugin