84% acymailing-integration-for-woocommerce

Code Review | WooCommerce integration - AcyMailing

WordPress plugin WooCommerce integration - AcyMailing scored84%from 54 tests.

About plugin

  • Plugin page: acymailing-integr...
  • Plugin version: 5.0
  • PHP compatiblity: 7.2.0+
  • PHP version: 7.4.16
  • WordPress compatibility: 4.7-6.3
  • WordPress version: 6.3.1
  • First release: Oct 1, 2020
  • Latest release: Aug 17, 2023
  • Number of updates: 38
  • Update frequency: every 27.7 days
  • Top authors: acyba (100%)

Code review

54 tests

User reviews

1 review

Install metrics

300+ active /8,921 total downloads

Benchmarks

Plugin footprint 83% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | It is important to correctly install your plugin, without throwing errors or notices
The plugin installed gracefully, with no errors

Server metrics [RAM: ▲0.01MB] [CPU: ▼9.50ms] Passed 4 tests

Analyzing server-side resources used by WooCommerce integration - AcyMailing
Normal server usage
PageMemory (MB)CPU Time (ms)
Home /3.48 ▲0.0234.32 ▼4.54
Dashboard /wp-admin3.32 ▲0.0242.92 ▼4.33
Posts /wp-admin/edit.php3.37 ▲0.0148.56 ▼3.01
Add New Post /wp-admin/post-new.php5.90 ▲0.0183.74 ▼26.13
Media Library /wp-admin/upload.php3.24 ▲0.0135.43 ▲2.47

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

Filesystem and database footprint
The plugin installed successfully
Filesystem: 14 new files
Database: no new tables, 6 new options
New WordPress options
db_upgraded
widget_recent-comments
can_compress_scripts
widget_recent-posts
theysaidso_admin_options
widget_theysaidso_widget

Browser metrics Passed 4 tests

WooCommerce integration - AcyMailing: an overview of browser usage
This plugin has a minimal impact on browser resources
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,825 ▲9013.65 ▼0.804.25 ▲2.3540.79 ▼3.38
Dashboard /wp-admin2,206 ▲185.89 ▲1.02112.21 ▲8.5842.34 ▼2.82
Posts /wp-admin/edit.php2,089 ▼32.04 ▲0.0740.47 ▼3.1434.88 ▲0.16
Add New Post /wp-admin/post-new.php1,544 ▲218.37 ▲0.32596.57 ▼21.6553.65 ▼4.60
Media Library /wp-admin/upload.php1,388 ▼04.22 ▲0.01101.25 ▲3.3140.51 ▼2.67

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

🔸 Tests weight: 35 | Checking the uninstaller removed all traces of the plugin
The following items require your attention
  • Zombie WordPress options detected upon uninstall: 6 options
    • widget_theysaidso_widget
    • widget_recent-posts
    • widget_recent-comments
    • db_upgraded
    • can_compress_scripts
    • theysaidso_admin_options

Smoke tests 75% from 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | A smoke test targeting server-side errors
Even though no errors were found, this is by no means an exhaustive test

SRP 50% from 2 tests

🔹 Tests weight: 20 | SRP (Single-Responsibility Principle) - PHP files must act as libraries and never output text or perform any action when accessed directly in a browser
The following issues need your attention
  • 2× GET requests to PHP files have triggered server-side errors or warnings:
    • > PHP Fatal error
      Uncaught Error: Class 'AcyMailing\\Libraries\\acymPlugin' not found in wp-content/plugins/acymailing-integration-for-woocommerce/plugin.php:16
    • > PHP Fatal error
      Uncaught Error: Call to undefined function register_deactivation_hook() in wp-content/plugins/acymailing-integration-for-woocommerce/acymailing-woocommerce.php:13

User-side errors Passed 1 test

🔹 Test weight: 20 | This is a smoke test targeting browser errors/issues
No browser issues were found

Optimizations

Plugin configuration 96% from 29 tests

readme.txt Passed 16 tests

Don't ignore readme.txt as it is the file that instructs WordPress.org on how to present your plugin to the world
4 plugin tags: newsletter, woocommerce, acymailing, integration

acymailing-integration-for-woocommerce/acymailing-woocommerce.php 92% from 13 tests

Analyzing the main PHP file in "WooCommerce integration - AcyMailing" version 5.0
Please take the time to fix the following:
  • Main file name: Even though not officially enforced, the main plugin file should be the same as the plugin slug ("acymailing-integration-for-woocommerce.php" instead of "acymailing-woocommerce.php")

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | An overview of files in this plugin; executable files are not allowed
Success! There were no dangerous files found in this plugin2,738 lines of code in 11 files:
LanguageFilesBlank linesComment linesLines of code
PHP11390582,738

PHP code Passed 2 tests

A brief analysis of cyclomatic complexity and code structure for this plugin
All good! No complexity issues found
Cyclomatic complexity
Average complexity per logical line of code0.40
Average class complexity36.60
▷ Minimum class complexity1.00
▷ Maximum class complexity128.00
Average method complexity5.62
▷ Minimum method complexity1.00
▷ Maximum method complexity36.00
Code structure
Namespaces0
Interfaces0
Traits9
Classes1
▷ Abstract classes00.00%
▷ Concrete classes1100.00%
▷ Final classes00.00%
Methods77
▷ Static methods00.00%
▷ Public methods6077.92%
▷ Protected methods00.00%
▷ Private methods1722.08%
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

It is recommended to compress PNG files in your plugin to minimize bandwidth usage
2 PNG files occupy 0.03MB with 0.01MB in potential savings
Potential savings
Compression of 2 random PNG files using pngquant
FileSize - originalSize - compressedSavings
icon.png13.44KB13.28KB▼ 1.21%
banner.png15.24KB6.22KB▼ 59.22%