79% proteusthemes-mailchimp-widget

Code Review | Mailchimp Widget by ProteusThemes

WordPress plugin Mailchimp Widget by ProteusThemes scored 79% from 54 tests.

About plugin

  • Plugin page: proteusthemes-mai...
  • Plugin version: 1.0.5
  • PHP version: 7.4.16
  • WordPress compatibility: 4.6-5.4.1
  • WordPress version: 6.3.1
  • First release: Jul 6, 2017
  • Latest release: May 31, 2020
  • Number of updates: 12
  • Update frequency: every 88.4 days
  • Top authors: proteusthemes (100%)

Code review

54 tests

User reviews

2 reviews

Install metrics

2,000+ active / 46,271 total downloads

Benchmarks

Plugin footprint 83% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | Verifying that this plugin installs correctly without errors
The plugin installed gracefully, with no errors

Server metrics [RAM: ▲0.06MB] [CPU: ▼3.79ms] Passed 4 tests

Analyzing server-side resources used by Mailchimp Widget by ProteusThemes
This plugin does not affect your website's performance
PageMemory (MB)CPU Time (ms)
Home /3.52 ▲0.0636.72 ▼3.35
Dashboard /wp-admin3.37 ▲0.0649.51 ▲2.38
Posts /wp-admin/edit.php3.42 ▲0.0648.24 ▼4.78
Add New Post /wp-admin/post-new.php5.97 ▲0.0886.81 ▼8.30
Media Library /wp-admin/upload.php3.29 ▲0.0634.71 ▲1.26

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

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

Browser metrics Passed 4 tests

Checking browser requirements for Mailchimp Widget by ProteusThemes
Minimal impact on browser resources
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,807 ▲7213.21 ▼1.051.68 ▲0.1238.33 ▼12.77
Dashboard /wp-admin2,208 ▲205.79 ▼0.07106.15 ▼5.5439.37 ▼4.01
Posts /wp-admin/edit.php2,094 ▲52.02 ▼0.1639.25 ▲2.5633.80 ▼2.71
Add New Post /wp-admin/post-new.php1,533 ▼923.36 ▲5.09628.61 ▲7.6660.91 ▼10.44
Media Library /wp-admin/upload.php1,390 ▲54.23 ▲0.0598.28 ▼2.7242.92 ▼0.93

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

🔸 Tests weight: 35 | Verifying that this plugin uninstalls completely without leaving any traces
It is recommended to fix the following
  • This plugin did not uninstall successfully, leaving 7 options in the database
    • widget_pt_mailchimp_subscribe
    • widget_recent-comments
    • widget_theysaidso_widget
    • widget_recent-posts
    • db_upgraded
    • theysaidso_admin_options
    • can_compress_scripts

Smoke tests 50% from 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | This is a short smoke test looking for server-side errors
Even though everything seems fine, this is not an exhaustive test

SRP 0% from 2 tests

🔹 Tests weight: 20 | The single-responsibility principle: PHP files have to remain inert when accessed directly, throwing no errors and performing no actions
Please fix the following items
  • 1× GET requests to PHP files return non-empty strings:
    • > /wp-content/plugins/proteusthemes-mailchimp-widget/proteusthemes-mailchimp-widget.php
  • 1× PHP files trigger server errors when accessed directly:
    • > PHP Fatal error
      Uncaught Error: Class 'WP_Widget' not found in wp-content/plugins/proteusthemes-mailchimp-widget/inc/widget-mailchimp-subscribe.php:12

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 Passed 29 tests

readme.txt Passed 16 tests

You should put a lot of thought into formatting readme.txt as it is used by WordPress.org to prepare the public listing of your plugin
9 plugin tags: form, plugin, email, subscribe, widget...

proteusthemes-mailchimp-widget/proteusthemes-mailchimp-widget.php Passed 13 tests

The principal PHP file in "Mailchimp Widget by ProteusThemes" v. 1.0.5 is loaded by WordPress automatically on each request
125 characters long description:
Mailchimp widget with API integration, that allows you to select which Mailchimp list you want your visitors to subscribe to.

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | Executable files are not allowed as they can serve as attack vectors
Everything looks great! No dangerous files found in this plugin307 lines of code in 4 files:
LanguageFilesBlank linesComment linesLines of code
PHP26486190
JavaScript1232288
CSS12029

PHP code Passed 2 tests

This is a short overview of cyclomatic complexity and code structure for this plugin
Although this was not an exhaustive test, there were no cyclomatic complexity issues detected
Cyclomatic complexity
Average complexity per logical line of code0.26
Average class complexity12.00
▷ Minimum class complexity6.00
▷ Maximum class complexity18.00
Average method complexity3.00
▷ Minimum method complexity1.00
▷ Maximum method complexity7.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes2
▷ Abstract classes00.00%
▷ Concrete classes2100.00%
▷ Final classes00.00%
Methods11
▷ Static methods436.36%
▷ Public methods1090.91%
▷ Protected methods00.00%
▷ Private methods19.09%
Functions0
▷ Named functions00.00%
▷ Anonymous functions00.00%
Constants3
▷ Global constants3100.00%
▷ Class constants00.00%
▷ Public constants00.00%

Plugin size Passed 2 tests

Image compression Passed 2 tests

Using a strong compression for your PNG files is a great way to speed-up your plugin
There were not PNG files found in your plugin