84% affiliates-manager-woocommerce-subscription-integration

Code Review | Affiliates Manager WooCommerce Subscription Integration

WordPress plugin Affiliates Manager WooCommerce Subscription Integration scored84%from 54 tests.

About plugin

  • Plugin page: affiliates-manage...
  • Plugin version: 1.1.4
  • PHP version: 7.4.16
  • WordPress compatibility: 3.8-6.3
  • WordPress version: 6.3.1
  • First release: Feb 25, 2015
  • Latest release: Sep 23, 2023
  • Number of updates: 17
  • Update frequency: every 184.2 days
  • Top authors: affmngr (100%)

Code review

54 tests

User reviews

1 review

Install metrics

200+ active /9,016 total downloads

Benchmarks

Plugin footprint 83% from 16 tests

Installer Passed 1 test

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

Server metrics [RAM: ▲0.04MB] [CPU: ▼1.68ms] Passed 4 tests

A check of server-side resources used by Affiliates Manager WooCommerce Subscription Integration
This plugin does not affect your website's performance
PageMemory (MB)CPU Time (ms)
Home /3.50 ▲0.0438.95 ▼6.06
Dashboard /wp-admin3.35 ▲0.0451.24 ▲4.86
Posts /wp-admin/edit.php3.40 ▲0.0451.88 ▼0.03
Add New Post /wp-admin/post-new.php5.93 ▲0.0499.49 ▲0.95
Media Library /wp-admin/upload.php3.27 ▲0.0436.17 ▼1.56

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

Filesystem and database footprint
No storage issues were detected
Filesystem: 3 new files
Database: no new tables, 6 new options
New WordPress options
db_upgraded
can_compress_scripts
theysaidso_admin_options
widget_recent-posts
widget_theysaidso_widget
widget_recent-comments

Browser metrics Passed 4 tests

Affiliates Manager WooCommerce Subscription Integration: an overview of browser usage
Normal browser usage
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,789 ▲2814.34 ▼0.051.84 ▲0.0842.81 ▲3.29
Dashboard /wp-admin2,195 ▲285.55 ▼0.1388.59 ▼5.8440.52 ▼3.25
Posts /wp-admin/edit.php2,100 ▼02.00 ▼0.0339.36 ▼3.1835.92 ▼5.42
Add New Post /wp-admin/post-new.php1,545 ▼023.20 ▼0.10636.14 ▼21.4353.68 ▲2.36
Media Library /wp-admin/upload.php1,400 ▲34.21 ▼0.0499.56 ▼16.5646.00 ▼8.18

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
    • widget_recent-posts
    • theysaidso_admin_options
    • can_compress_scripts
    • db_upgraded
    • widget_recent-comments

Smoke tests 75% from 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | This is a shallow check for server-side errors
Even though everything seems fine, this is not 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 fix the following items
  • 1× PHP files trigger errors when accessed directly with GET requests:
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_action() in wp-content/plugins/affiliates-manager-woocommerce-subscription-integration/affiliatemgr-wc-subscription-settings.php:3

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 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
7 plugin tags: affiliate, integration, affiliates manager, affiliates, subscription...

affiliates-manager-woocommerce-subscription-integration/affiliatemgr-wc-subscription-integration.php 92% from 13 tests

The main PHP script in "Affiliates Manager WooCommerce Subscription Integration" version 1.1.4 is automatically included on every request by WordPress
You should first fix the following items:
  • Main file name: It is recommended to name the main PHP file as the plugin slug ("affiliates-manager-woocommerce-subscription-integration.php" instead of "affiliatemgr-wc-subscription-integration.php")

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | A short review of files and their extensions; it is not recommended to include executable files
There were no executable files found in this plugin175 lines of code in 2 files:
LanguageFilesBlank linesComment linesLines of code
PHP21870175

PHP code Passed 2 tests

An short overview of logical lines of code, cyclomatic complexity, and other code metrics
There are no cyclomatic complexity problems detected for this plugin
Cyclomatic complexity
Average complexity per logical line of code0.25
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%
Functions4
▷ Named functions4100.00%
▷ Anonymous functions00.00%
Constants0
▷ Global constants00.00%
▷ Class constants00.00%
▷ Public constants00.00%

Plugin size Passed 2 tests

Image compression Passed 2 tests

Often times overlooked, PNG files can occupy unnecessary space in your plugin
There were not PNG files found in your plugin