10% simple-email-mailchimp-subscriber

Code Review | Simple Email & MailChimp Subscriber

WordPress plugin Simple Email & MailChimp Subscriber scored10%from 54 tests.

About plugin

  • Plugin page: simple-email-mail...
  • Plugin version: 2.2.3
  • PHP version: 7.4.16
  • WordPress compatibility: 3.0.1-5.5
  • WordPress version: 6.3.1
  • First release: May 24, 2019
  • Latest release: Aug 31, 2020
  • Number of updates: 12
  • Update frequency: every 38.9 days
  • Top authors: wpmonkeys (100%)

Code review

54 tests

User reviews

1 review

Install metrics

40+ active /1,139 total downloads

Benchmarks

Plugin footprint 40% from 16 tests

Installer 0% from 1 test

🔺 Critical test (weight: 50) | It is important to correctly install your plugin, without throwing errors or notices
The following installer errors require your attention
  • Install procedure validation failed for this plugin
    • > Notice in wp-content/plugins/simple-email-mailchimp-subscriber/includes/class-functions.php+34
    Trying to access array offset on value of type bool

Server metrics [RAM: ▲1.77MB] [CPU: ▼36.71ms] Passed 4 tests

Server-side resources used by Simple Email & MailChimp Subscriber
This plugin does not affect your website's performance
PageMemory (MB)CPU Time (ms)
Home /5.76 ▲2.3018.41 ▼21.76
Dashboard /wp-admin5.78 ▲2.4720.10 ▼29.39
Posts /wp-admin/edit.php5.78 ▲2.4221.90 ▼23.22
Add New Post /wp-admin/post-new.php5.78 ▼0.1118.39 ▼72.46
Media Library /wp-admin/upload.php5.78 ▲2.5524.31 ▼11.63
Subscriber List /wp-admin/edit.php?post_type=wpmsems_subscriber5.7822.91
Add New /wp-admin/post-new.php?post_type=wpmsems_subscriber5.7820.11
Settings /wp-admin/edit.php?post_type=wpmsems_subscriber&page=wpmsems-settings5.7819.04

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

How much does this plugin use your filesystem and database?
There were no storage issued detected upon installing this plugin
Filesystem: 103 new files
Database: no new tables, 6 new options
New WordPress options
widget_recent-comments
theysaidso_admin_options
can_compress_scripts
widget_recent-posts
widget_theysaidso_widget
db_upgraded

Browser metrics Passed 4 tests

This is an overview of browser requirements for Simple Email & MailChimp Subscriber
This plugin renders optimally with no browser resource issues detected
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,894 ▲13714.15 ▼0.131.69 ▼0.5640.96 ▼4.68
Dashboard /wp-admin2,292 ▲1045.73 ▲0.84117.56 ▲11.4541.29 ▼0.56
Posts /wp-admin/edit.php2,182 ▲932.93 ▲0.9244.98 ▲9.7732.66 ▲0.99
Add New Post /wp-admin/post-new.php1,748 ▲23423.29 ▲5.89702.25 ▲3.0637.80 ▼15.67
Media Library /wp-admin/upload.php1,474 ▲895.04 ▲0.91115.38 ▲14.3247.16 ▲3.09
Subscriber List /wp-admin/edit.php?post_type=wpmsems_subscriber1,1682.6038.3928.83
Add New /wp-admin/post-new.php?post_type=wpmsems_subscriber1,7053.4356.5441.74
Settings /wp-admin/edit.php?post_type=wpmsems_subscriber&page=wpmsems-settings1,9967.86142.6032.71

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

🔸 Tests weight: 35 | It is important to correctly uninstall your plugin, without leaving any traces
Please fix the following items
  • This plugin did not uninstall without warnings or errors
    • > Notice in wp-content/plugins/simple-email-mailchimp-subscriber/includes/class-functions.php+34
    Trying to access array offset on value of type bool
  • The uninstall procedure has failed, leaving 6 options in the database
    • db_upgraded
    • widget_theysaidso_widget
    • widget_recent-comments
    • widget_recent-posts
    • can_compress_scripts
    • theysaidso_admin_options

Smoke tests 50% from 4 tests

Server-side errors 0% from 1 test

🔹 Test weight: 20 | A shallow check that no server-side errors were triggered
Please fix the following server-side errors
  • 4 occurences, only the last one shown
    • > GET request to /wp-admin/edit.php?post_type=wpmsems_subscriber&page=wpmsems-settings
    • > Notice in wp-content/plugins/simple-email-mailchimp-subscriber/includes/class-functions.php+34
    Trying to access array offset on value of type bool
    • > GET request to /wp-admin/post-new.php?post_type=wpmsems_subscriber
    • > Notice in wp-content/plugins/simple-email-mailchimp-subscriber/lib/classes/class-meta-box.php+107
    Undefined index: page_nav

SRP 50% from 2 tests

🔹 Tests weight: 20 | The single-responsibility principle applies for WordPress plugins as well - please make sure your PHP files perform no actions when accessed directly
Please fix the following items
  • 9× GET requests to PHP files have triggered server-side errors or warnings:
    • > PHP Fatal error
      Uncaught Error: Class 'WPM_Setting_API' not found in wp-content/plugins/simple-email-mailchimp-subscriber/inc/wpmsems_admin_setting_panel.php:14
    • > PHP Warning
      include_once(ABSPATHwp-admin/includes/plugin.php): failed to open stream: No such file or directory in wp-content/plugins/simple-email-mailchimp-subscriber/support/elementor/elementor-support.php on line 47
    • > PHP Fatal error
      Uncaught Error: Call to undefined function is_plugin_active() in wp-content/plugins/simple-email-mailchimp-subscriber/support/elementor/elementor-support.php:48
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_action() in wp-content/plugins/simple-email-mailchimp-subscriber/includes/class-upgrade.php:2
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_action() in wp-content/plugins/simple-email-mailchimp-subscriber/includes/class_csv_export.php:2
    • > PHP Parse error
      syntax error, unexpected end of file in wp-content/plugins/simple-email-mailchimp-subscriber/inc/wpmsems_shortcode.php on line 103
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_action() in wp-content/plugins/simple-email-mailchimp-subscriber/inc/wpmsems_subscriber_list.php:3
    • > PHP Warning
      include_once(): Failed opening 'ABSPATHwp-admin/includes/plugin.php' for inclusion (include_path='.:/usr/share/php') in wp-content/plugins/simple-email-mailchimp-subscriber/support/elementor/elementor-support.php on line 47
    • > PHP Warning
      Use of undefined constant ABSPATH - assumed 'ABSPATH' (this will throw an Error in a future version of PHP) in wp-content/plugins/simple-email-mailchimp-subscriber/support/elementor/elementor-support.php on line 47

User-side errors Passed 1 test

🔹 Test weight: 20 | Just a short smoke test targeting errors on the browser (console and network errors and warnings)
No browser issues were found

Optimizations

Plugin configuration 93% from 29 tests

readme.txt 94% from 16 tests

Often overlooked, readme.txt is one of the most important files in your plugin
Please fix the following attributes: Please take inspiration from this readme.txt

simple-email-mailchimp-subscriber/wpm-mailchimp.php 92% from 13 tests

The entry point to "Simple Email & MailChimp Subscriber" version 2.2.3 is a PHP file that has certain tags in its header comment area
Please make the necessary changes and fix the following:
  • Main file name: It is recommended to name the main PHP file as the plugin slug ("simple-email-mailchimp-subscriber.php" instead of "wpm-mailchimp.php")

Code Analysis 95% from 3 tests

File types Passed 1 test

🔸 Test weight: 35 | This is an overview of file extensions present in this plugin and a short test that no dangerous files are bundled with this plugin
No dangerous file extensions were detected29,629 lines of code in 62 files:
LanguageFilesBlank linesComment linesLines of code
PHP324,28387419,614
CSS125722713,708
JavaScript157878053,427
SVG30122,880

PHP code 0% from 2 tests

Analyzing logical lines of code, cyclomatic complexity, and other code metrics
These items need your attention
  • Class cyclomatic complexity has to be reduced to less than 1000 (currently 2,588)
  • Please reduce cyclomatic complexity of methods to less than 100 (currently 122)
Cyclomatic complexity
Average complexity per logical line of code0.49
Average class complexity246.91
▷ Minimum class complexity1.00
▷ Maximum class complexity2,588.00
Average method complexity16.87
▷ Minimum method complexity1.00
▷ Maximum method complexity122.00
Code structure
Namespaces3
Interfaces0
Traits0
Classes22
▷ Abstract classes00.00%
▷ Concrete classes22100.00%
▷ Final classes00.00%
Methods341
▷ Static methods10.29%
▷ Public methods26978.89%
▷ Protected methods30.88%
▷ Private methods6920.23%
Functions20
▷ Named functions20100.00%
▷ Anonymous functions00.00%
Constants6
▷ Global constants466.67%
▷ Class constants233.33%
▷ Public constants2100.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
22 PNG files occupy 0.06MB with 0.02MB in potential savings
Potential savings
Compression of 5 random PNG files using pngquant
FileSize - originalSize - compressedSavings
admin/css/images/ui-icons_454545_256x240.png4.27KB4.11KB▼ 3.78%
admin/assets/css/images/ui-icons_777777_256x240.png6.85KB4.18KB▼ 38.94%
admin/css/images/ui-icons_888888_256x240.png4.27KB4.11KB▼ 3.78%
admin/css/images/ui-bg_glass_55_fbf9ee_1x400.png0.12KB0.14KB0.00%
admin/css/images/arrow_down.png1.06KB0.24KB▼ 77.47%