84% edd-mailchimp-subscribe

Code Review | EDD Mailchimp Subscribe

WordPress plugin EDD Mailchimp Subscribe scored84%from 54 tests.

About plugin

  • Plugin page: edd-mailchimp-sub...
  • Plugin version: 1.3
  • PHP version: 7.4.16
  • WordPress compatibility: 3.5-5.8
  • WordPress version: 6.3.1
  • First release: Apr 7, 2014
  • Latest release: Jun 12, 2021
  • Number of updates: 25
  • Update frequency: every 105.7 days
  • Top authors: aman086 (100%)

Code review

54 tests

User reviews

4 reviews

Install metrics

80+ active /4,406 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.03MB] [CPU: ▼0.04ms] Passed 4 tests

This is a short check of server-side resources used by EDD Mailchimp Subscribe
Server-side resource usage in normal parameters
PageMemory (MB)CPU Time (ms)
Home /3.49 ▲0.0339.46 ▼2.70
Dashboard /wp-admin3.43 ▲0.1349.50 ▼0.64
Posts /wp-admin/edit.php3.38 ▲0.0349.90 ▲0.07
Add New Post /wp-admin/post-new.php5.91 ▲0.0395.42 ▲4.26
Media Library /wp-admin/upload.php3.26 ▲0.0340.20 ▲3.09

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

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

Browser metrics Passed 4 tests

An overview of browser requirements for EDD Mailchimp Subscribe
This plugin renders optimally with no browser resource issues detected
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,908 ▲17313.59 ▼0.661.59 ▼0.2131.23 ▼15.17
Dashboard /wp-admin2,314 ▲1235.87 ▲0.96108.74 ▲3.8146.66 ▼1.85
Posts /wp-admin/edit.php2,089 ▼02.04 ▲0.0339.69 ▲1.6334.87 ▼2.55
Add New Post /wp-admin/post-new.php1,514 ▼2117.72 ▼3.52653.17 ▼61.6849.47 ▼7.31
Media Library /wp-admin/upload.php1,388 ▼04.21 ▼0.0194.99 ▼19.0746.00 ▲0.28

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

🔸 Tests weight: 35 | The uninstall procedure must remove all plugin files and extra database tables
You still need to fix the following
  • Zombie WordPress options detected upon uninstall: 6 options
    • db_upgraded
    • widget_theysaidso_widget
    • widget_recent-comments
    • can_compress_scripts
    • theysaidso_admin_options
    • widget_recent-posts

Smoke tests 75% from 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | A smoke test targeting server-side errors
Good news, no errors were detected

SRP 50% from 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
Please fix the following
  • 1× PHP files trigger server-side errors or warnings when accessed directly:
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_action() in wp-content/plugins/edd-mailchimp-subscribe/edd_mailchimp_subscribe.php:26

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 uses markdown syntax to describe your plugin to the world
4 plugin tags: edd mailchimp, easy digital downloads, mailchimp integration, mailchimp

edd-mailchimp-subscribe/edd_mailchimp_subscribe.php 92% from 13 tests

Analyzing the main PHP file in "EDD Mailchimp Subscribe" version 1.3
Please take the time to fix the following:
  • Main file name: Name the main plugin file the same as the plugin slug ("edd-mailchimp-subscribe.php" instead of "edd_mailchimp_subscribe.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
No dangerous file extensions were detected444 lines of code in 3 files:
LanguageFilesBlank linesComment linesLines of code
PHP2113233392
CSS17752

PHP code Passed 2 tests

An short overview of logical lines of code, cyclomatic complexity, and other code metrics
No cyclomatic complexity issues were detected for this plugin
Cyclomatic complexity
Average complexity per logical line of code0.30
Average class complexity33.00
▷ Minimum class complexity33.00
▷ Maximum class complexity33.00
Average method complexity2.45
▷ Minimum method complexity1.00
▷ Maximum method complexity9.00
Code structure
Namespaces1
Interfaces0
Traits0
Classes1
▷ Abstract classes00.00%
▷ Concrete classes1100.00%
▷ Final classes00.00%
Methods22
▷ Static methods14.55%
▷ Public methods1359.09%
▷ Protected methods00.00%
▷ Private methods940.91%
Functions7
▷ Named functions7100.00%
▷ Anonymous functions00.00%
Constants1
▷ Global constants00.00%
▷ Class constants1100.00%
▷ Public constants1100.00%

Plugin size Passed 2 tests

Image compression Passed 2 tests

PNG files should be compressed to save space and minimize bandwidth usage
PNG images were not found in this plugin