10% simple-mailchimp

Code Review | Simple MailChimp

WordPress plugin Simple MailChimp scored10%from 54 tests.

About plugin

  • Plugin page: simple-mailchimp
  • Plugin version: 1.2
  • PHP version: 7.4.16
  • WordPress compatibility: 3.0-5.0
  • WordPress version: 6.3.1
  • First release: Nov 10, 2015
  • Latest release: Dec 10, 2018
  • Number of updates: 8
  • Update frequency: every 140.8 days
  • Top authors: 2biazdk (100%)

Code review

54 tests

User reviews

1 review

Install metrics

10+ active /880 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
You still need to fix the following installer errors
  • This plugin did not install gracefully
    • > Notice in wp-content/plugins/simple-mailchimp/simple-mailchimp.php+315
    Undefined index: simple_mailchimp_firstname

Server metrics [RAM: ▼1.88MB] [CPU: ▼53.81ms] Passed 4 tests

Analyzing server-side resources used by Simple MailChimp
Normal server usage
PageMemory (MB)CPU Time (ms)
Home /2.11 ▼1.364.67 ▼36.03
Dashboard /wp-admin2.13 ▼1.185.70 ▼46.22
Posts /wp-admin/edit.php2.13 ▼1.236.17 ▼54.77
Add New Post /wp-admin/post-new.php2.13 ▼3.764.71 ▼78.20
Media Library /wp-admin/upload.php2.13 ▼1.116.06 ▼28.04
Simple MailChimp /wp-admin/options-general.php?page=simple-mailchimp-settings2.135.63

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

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

Browser metrics Passed 4 tests

This is an overview of browser requirements for Simple MailChimp
This plugin has a minimal impact on browser resources
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,830 ▲9513.20 ▼1.194.91 ▲3.1837.61 ▼11.87
Dashboard /wp-admin2,211 ▲265.01 ▲0.08113.06 ▼27.7642.72 ▼1.18
Posts /wp-admin/edit.php2,094 ▲52.06 ▲0.0839.43 ▲3.4634.11 ▼0.12
Add New Post /wp-admin/post-new.php1,517 ▼217.69 ▼5.39641.46 ▼14.9054.86 ▲1.72
Media Library /wp-admin/upload.php1,393 ▲114.25 ▲0.0791.72 ▼5.9841.95 ▲0.83
Simple MailChimp /wp-admin/options-general.php?page=simple-mailchimp-settings9392.0224.5727.94

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
The following items require your attention
  • This plugin did not uninstall without warnings or errors
    • > Notice in wp-content/plugins/simple-mailchimp/simple-mailchimp.php+315
    Undefined index: simple_mailchimp_firstname
  • Zombie WordPress options detected upon uninstall: 9 options
    • simple_mailchimp_success_message
    • widget_theysaidso_widget
    • simple_mailchimp_error_message
    • widget_recent-comments
    • widget_recent-posts
    • db_upgraded
    • can_compress_scripts
    • simple_mailchimp_subscribe_status
    • theysaidso_admin_options

Smoke tests 25% from 4 tests

Server-side errors 0% from 1 test

🔹 Test weight: 20 | A shallow check that no server-side errors were triggered
These server-side errors were triggered
  • 2 occurences, only the last one shown
    • > GET request to /wp-admin/options-general.php?page=simple-mailchimp-settings
    • > Notice in wp-content/plugins/simple-mailchimp/simple-mailchimp.php+346
    Undefined index: simple_mailchimp_firstname
    • > GET request to /wp-admin/options-general.php?page=simple-mailchimp-settings
    • > Notice in wp-content/plugins/simple-mailchimp/simple-mailchimp.php+87
    Undefined index: submit
    • > GET request to /wp-admin/options-general.php?page=simple-mailchimp-settings
    • > Notice in wp-content/plugins/simple-mailchimp/simple-mailchimp.php+88
    Undefined index: api_key
    • > GET request to /wp-admin/options-general.php?page=simple-mailchimp-settings
    • > Notice in wp-content/plugins/simple-mailchimp/simple-mailchimp.php+89
    Undefined index: default_list_id
    • > GET request to /wp-admin/options-general.php?page=simple-mailchimp-settings
    • > Notice in wp-content/plugins/simple-mailchimp/simple-mailchimp.php+90
    Undefined index: subscribe_status
    • > GET request to /wp-admin/options-general.php?page=simple-mailchimp-settings
    • > Notice in wp-content/plugins/simple-mailchimp/simple-mailchimp.php+91
    Undefined index: success_message
    • > GET request to /wp-admin/options-general.php?page=simple-mailchimp-settings
    • > Notice in wp-content/plugins/simple-mailchimp/simple-mailchimp.php+92
    Undefined index: error_message
    • > GET request to /wp-admin/options-general.php?page=simple-mailchimp-settings
    • > Notice in wp-content/plugins/simple-mailchimp/simple-mailchimp.php+342
    Undefined index: simple_mailchimp_email
    • > GET request to /wp-admin/options-general.php?page=simple-mailchimp-settings
    • > Notice in wp-content/plugins/simple-mailchimp/simple-mailchimp.php+350
    Undefined index: simple_mailchimp_lastname

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
Almost there! Just fix the following items
  • 1× PHP files output non-empty strings when accessed directly via GET requests:
    • > /wp-content/plugins/simple-mailchimp/simple-mailchimp.php

User-side errors 0% from 1 test

🔹 Test weight: 20 | A shallow check that no browser errors were triggered
Please fix the following browser errors
    • > GET request to /wp-admin/options-general.php?page=simple-mailchimp-settings
    • > Network (severe)
    wp-content/plugins/simple-mailchimp/style.css - Failed to load resource: the server responded with a status of 404 (Not Found)

Optimizations

Plugin configuration 97% from 29 tests

readme.txt 94% from 16 tests

The readme.txt file is important because it is parsed by WordPress.org for the public listing of your plugin
Please fix the following attributes: The official readme.txt is a good inspiration

simple-mailchimp/simple-mailchimp.php Passed 13 tests

The main PHP file in "Simple MailChimp" ver. 1.2 adds more information about the plugin and also serves as the entry point for this plugin
96 characters long description:
Add a simple MailChimp form to any page, post or template file using shortcodes. Quick and easy!

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | A short glimpse at programming languages used with this plugin and a check that no dangerous files are present
There were no executable files found in this plugin274 lines of code in 2 files:
LanguageFilesBlank linesComment linesLines of code
PHP29226274

PHP code Passed 2 tests

Analyzing logical lines of code, cyclomatic complexity, and other code metrics
This plugin has no cyclomatic complexity issues
Cyclomatic complexity
Average complexity per logical line of code0.21
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%
Functions11
▷ Named functions11100.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
1 PNG file occupies 0.00MB with 0.00MB in potential savings
Potential savings
Compression of 1 random PNG file using pngquant
FileSize - originalSize - compressedSavings
img/settings-icon.png2.65KB1.80KB▼ 32.30%