10% mailchimp-importer

Code Review | MailChimp Importer

WordPress plugin MailChimp Importer scored10%from 54 tests.

About plugin

  • Plugin page: mailchimp-importer
  • Plugin version: 1.0
  • PHP version: 7.4.16
  • WordPress compatibility: 3.0.1-3.5
  • WordPress version: 6.3.1
  • First release: Feb 5, 2013
  • Latest release: Feb 5, 2013
  • Number of updates: 4
  • Update frequency: N/A
  • Top authors: kreitje (100%)

Code review

54 tests

User reviews

1 review

Install metrics

30+ active /2,156 total downloads

Benchmarks

Plugin footprint 58% 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
Please fix the following installer errors
  • The plugin did not install without errors
    • > Deprecated in wp-content/plugins/mailchimp-importer/mcapi/MCAPI.class.php+3
    Methods with the same name as their class will not be constructors in a future version of PHP; MCAPI has a deprecated constructor

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

This is a short check of server-side resources used by MailChimp Importer
No issues were detected with server-side resource usage
PageMemory (MB)CPU Time (ms)
Home /3.47 ▲0.0136.93 ▼4.97
Dashboard /wp-admin3.32 ▲0.0244.20 ▼3.96
Posts /wp-admin/edit.php3.37 ▲0.0247.65 ▲2.80
Add New Post /wp-admin/post-new.php5.90 ▲0.0287.63 ▼4.07
Media Library /wp-admin/upload.php3.24 ▲0.0235.48 ▲2.52
MailChimp Importer /wp-admin/options-general.php?page=mailchimp-importer/hms-mailchimp.php3.1931.19

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

Analyzing filesystem and database footprints of this plugin
This plugin was installed successfully
Filesystem: 4 new files
Database: no new tables, 6 new options
New WordPress options
widget_recent-comments
can_compress_scripts
db_upgraded
widget_recent-posts
widget_theysaidso_widget
theysaidso_admin_options

Browser metrics Passed 4 tests

A check of browser resources used by MailChimp Importer
There were no issues detected in relation to browser resource usage
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,804 ▲5814.48 ▲0.131.64 ▼0.3541.52 ▼4.57
Dashboard /wp-admin2,207 ▲165.94 ▲1.01109.77 ▲3.2839.36 ▼7.16
Posts /wp-admin/edit.php2,093 ▲72.05 ▼0.0138.97 ▲0.8933.89 ▼2.60
Add New Post /wp-admin/post-new.php1,517 ▼717.51 ▼5.93665.27 ▲3.0562.49 ▲7.67
Media Library /wp-admin/upload.php1,389 ▼24.35 ▲0.1293.49 ▼4.4640.90 ▼2.31
MailChimp Importer /wp-admin/options-general.php?page=mailchimp-importer/hms-mailchimp.php9162.0131.6926.27

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

🔸 Tests weight: 35 | It is important to correctly uninstall your plugin, without leaving any traces
It is recommended to fix the following
  • This plugin does not fully uninstall, leaving 6 options in the database
    • db_upgraded
    • widget_recent-posts
    • theysaidso_admin_options
    • can_compress_scripts
    • widget_recent-comments
    • widget_theysaidso_widget

Smoke tests 50% from 4 tests

Server-side errors 0% from 1 test

🔹 Test weight: 20 | This is a short smoke test looking for server-side errors
These errors were triggered by the plugin
    • > GET request to /wp-admin/options-general.php?page=mailchimp-importer/hms-mailchimp.php
    • > User deprecated in wp-includes/functions.php+5463
    Function screen_icon is deprecated since version 3.8.0 with no alternative available.
    • > GET request to /wp-admin/options-general.php?page=mailchimp-importer/hms-mailchimp.php
    • > User deprecated in wp-includes/functions.php+5463
    Function get_screen_icon is deprecated since version 3.8.0 with no alternative available.
  • 14 occurences, only the last one shown
    • > GET request to /wp-admin/options-general.php?page=mailchimp-importer/hms-mailchimp.php
    • > Notice in wp-content/plugins/mailchimp-importer/hms-mailchimp.php+229
    Trying to access array offset on value of type bool

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 take a closer look at the following
  • 1× GET requests to PHP files have triggered server-side errors or warnings:
    • > PHP Fatal error
      Uncaught Error: Call to undefined function plugin_dir_path() in wp-content/plugins/mailchimp-importer/hms-mailchimp.php:12

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 errors were detected

Optimizations

Plugin configuration 93% from 29 tests

readme.txt 94% from 16 tests

The readme.txt file uses markdown syntax to describe your plugin to the world
Attributes that require attention:
  • Plugin Name: "Plugin Name" should be replaced with the name of your plugin on the first line ( === mailchimp-importer === )
You can take inspiration from this readme.txt

mailchimp-importer/hms-mailchimp.php 92% from 13 tests

Analyzing the main PHP file in "MailChimp Importer" version 1.0
Please make the necessary changes and fix the following:
  • Main file name: The principal plugin file should be the same as the plugin slug ("mailchimp-importer.php" instead of "hms-mailchimp.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
Everything looks great! No dangerous files found in this plugin472 lines of code in 2 files:
LanguageFilesBlank linesComment linesLines of code
PHP213346472

PHP code Passed 2 tests

Analyzing 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.35
Average class complexity21.50
▷ Minimum class complexity21.00
▷ Maximum class complexity22.00
Average method complexity3.41
▷ Minimum method complexity1.00
▷ Maximum method complexity20.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes2
▷ Abstract classes00.00%
▷ Concrete classes2100.00%
▷ Final classes00.00%
Methods17
▷ Static methods15.88%
▷ Public methods17100.00%
▷ Protected methods00.00%
▷ Private methods00.00%
Functions6
▷ Named functions6100.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.01MB with 0.00MB in potential savings
Potential savings
Compression of 1 random PNG file using pngquant
FileSize - originalSize - compressedSavings
mcapi/mclogo.png7.08KB3.73KB▼ 47.35%