84% awin-advertiser-tracking

Code Review | Awin - Advertiser Tracking for WooCommerce

WordPress plugin Awin - Advertiser Tracking for WooCommerce scored84%from 54 tests.

About plugin

  • Plugin page: awin-advertiser-t...
  • Plugin version: 1.2.0
  • PHP version: 7.4.16
  • WordPress compatibility: 3.5-6.4
  • WordPress version: 6.3.1
  • First release: Jun 12, 2019
  • Latest release: Oct 20, 2023
  • Number of updates: 62
  • Update frequency: every 25.8 days
  • Top authors: awinglobal (100%)

Code review

54 tests

User reviews

3 reviews

Install metrics

1,000+ active /14,624 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
Install script ran successfully

Server metrics [RAM: ▲0.05MB] [CPU: ▼3.90ms] Passed 4 tests

An overview of server-side resources used by Awin - Advertiser Tracking for WooCommerce
No issues were detected with server-side resource usage
PageMemory (MB)CPU Time (ms)
Home /3.51 ▲0.0539.04 ▲1.85
Dashboard /wp-admin3.35 ▲0.0546.13 ▼1.61
Posts /wp-admin/edit.php3.40 ▲0.0545.42 ▼3.72
Add New Post /wp-admin/post-new.php5.93 ▲0.0581.99 ▼6.20
Media Library /wp-admin/upload.php3.27 ▲0.0531.01 ▼4.06

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

How much does this plugin use your filesystem and database?
This plugin was installed successfully
Filesystem: 5 new files
Database: no new tables, 6 new options
New WordPress options
widget_recent-posts
can_compress_scripts
widget_theysaidso_widget
widget_recent-comments
theysaidso_admin_options
db_upgraded

Browser metrics Passed 4 tests

An overview of browser requirements for Awin - Advertiser Tracking for WooCommerce
Minimal impact on browser resources
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,789 ▲2814.39 ▼0.141.73 ▲0.1143.48 ▲1.97
Dashboard /wp-admin2,192 ▲125.59 ▼0.0296.16 ▲11.5642.71 ▼0.78
Posts /wp-admin/edit.php2,079 ▼242.01 ▼0.0134.26 ▼11.3830.82 ▼9.45
Add New Post /wp-admin/post-new.php1,526 ▼223.05 ▼0.19667.86 ▲16.8355.64 ▲4.57
Media Library /wp-admin/upload.php1,400 ▼34.16 ▼0.0494.40 ▼1.8941.32 ▼3.78

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

🔸 Tests weight: 35 | Checking the uninstaller removed all traces of the plugin
You still need to fix the following
  • Zombie WordPress options were found after uninstall: 6 options
    • widget_theysaidso_widget
    • can_compress_scripts
    • widget_recent-posts
    • db_upgraded
    • widget_recent-comments
    • theysaidso_admin_options

Smoke tests 75% from 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | This is a short smoke test looking for server-side errors
Everything seems fine, however this is by no means an exhaustive test

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 take a closer look at the following
  • 1× PHP files trigger server errors when accessed directly:
    • > PHP Fatal error
      Uncaught Error: Call to undefined function apply_filters() in wp-content/plugins/awin-advertiser-tracking/awin-advertiser-tracking.php:25

User-side errors Passed 1 test

🔹 Test weight: 20 | This is a smoke test targeting browser errors/issues
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 an important file in your plugin as it is parsed by WordPress.org to prepare the public listing of your plugin
6 plugin tags: tracking, affiliate window, awin, affiliate, zanox...

awin-advertiser-tracking/awin-advertiser-tracking.php 92% from 13 tests

This is the main PHP file of "Awin - Advertiser Tracking for WooCommerce" version 1.2.0, providing information about the plugin in the header fields and serving as the principal entry point to the plugin's functions
Please take the time to fix the following:
  • Domain Path: The domain path points to an invalid folder, "/languages" does not exist

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | This is a short overview of programming languages used in this plugin, detecting executable files
Good job! No executable or dangerous file extensions detected242 lines of code in 2 files:
LanguageFilesBlank linesComment linesLines of code
PHP15123206
PO File16636

PHP code Passed 2 tests

Analyzing logical lines of code, cyclomatic complexity, and other code metrics
This plugin has no cyclomatic complexity problems
Cyclomatic complexity
Average complexity per logical line of code0.28
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%
Functions13
▷ Named functions13100.00%
▷ Anonymous functions00.00%
Constants7
▷ Global constants7100.00%
▷ Class constants00.00%
▷ Public constants00.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
No PNG files were detected