94% add-on-gravity-forms-mailpoet

Code Review | Add-on Gravity Forms - MailPoet 3

WordPress plugin Add-on Gravity Forms - MailPoet 3 scored 94% from 54 tests.

About plugin

  • Plugin page: add-on-gravity-fo...
  • Plugin version: 1.1.14
  • PHP compatiblity: 7.0+
  • PHP version: 7.4.16
  • WordPress compatibility: 5.0-5.5.1
  • WordPress version: 5.9.2
  • First release: Sep 14, 2017
  • Latest release: Oct 1, 2020
  • Number of updates: 26
  • Update frequency: every 42.8 days
  • Top authors: ehsantikweb (88.46%)Kasperta (15.38%)

Code review

54 tests

User reviews

5 reviews

Install metrics

2,000+ active / 17,586 total downloads

Benchmarks

Plugin footprint Passed 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | The install procedure must perform silently
The plugin installed gracefully, with no errors

Server metrics [RAM: ▲0.02MB] [CPU: ▼309.65ms] Passed 4 tests

Server-side resources used by Add-on Gravity Forms - MailPoet 3
This plugin has minimal impact on server resources
PageMemory (MB)CPU Time (ms)
Home /3.56 ▲0.0557.00 ▼18.76
Dashboard /wp-admin3.45 ▲0.0436.39 ▼0.65
Posts /wp-admin/edit.php3.68 ▲0.0438.89 ▼0.04
Add New Post /wp-admin/post-new.php6.92 ▼0.05104.28 ▼1,216.25
Media Library /wp-admin/upload.php3.33 ▲0.0423.31 ▼2.92

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

Filesystem and database footprint
This plugin was installed successfully
Filesystem: 21 new files
Database: no new tables, no new options

Browser metrics Passed 4 tests

A check of browser resources used by Add-on Gravity Forms - MailPoet 3
There were no issues detected in relation to browser resource usage
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /3,791 ▲3715.59 ▲0.235.85 ▼0.492.56 ▼0.43
Dashboard /wp-admin2,898 ▲376.12 ▼0.03123.48 ▼26.48207.11 ▲30.44
Posts /wp-admin/edit.php2,714 ▲263.23 ▲0.0063.03 ▼1.78140.46 ▲3.79
Add New Post /wp-admin/post-new.php1,673 ▼7916.28 ▼5.64422.20 ▼27.86181.05 ▼2.21
Media Library /wp-admin/upload.php1,715 ▲185.61 ▲0.11144.23 ▼15.05226.03 ▼3.92

Uninstaller [IO: ▲0.00MB] [DB: ▲0.00MB] Passed 4 tests

🔸 Tests weight: 35 | The uninstall procedure must remove all plugin files and extra database tables
Uninstaller ran successfully

Smoke tests 75% from 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | Just a short smoke test targeting errors on the server (in the Apache logs)
Everything seems fine, however this is by no means an exhaustive test

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
  • 2× GET requests to PHP files trigger server-side errors or Error 500 responses:
    • > PHP Fatal error
      Uncaught Error: Class 'GF_Field' not found in wp-content/plugins/add-on-gravity-forms-mailpoet/mailpoet-fields.php:6
    • > PHP Fatal error
      Uncaught Error: Class 'GFForms' not found in wp-content/plugins/add-on-gravity-forms-mailpoet/class-gfnewmailpoetaddon.php:6

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)
There were no browser issues found

Optimizations

Plugin configuration 93% from 29 tests

readme.txt 88% from 16 tests

The readme.txt file uses markdown syntax to describe your plugin to the world
Attributes that require attention:
  • Screenshots: Screenshot #1 (No screenshots yet.) image not found
  • Tags: Too many tags (21 tag instead of maximum 10); only the first 5 tags are used in your directory listing
The official readme.txt is a good inspiration

add-on-gravity-forms-mailpoet/add-on-gravity-forms-mailpoet.php Passed 13 tests

The main PHP file in "Add-on Gravity Forms - MailPoet 3" ver. 1.1.14 adds more information about the plugin and also serves as the entry point for this plugin
52 characters long description:
Add a MailPoet 3 signup field to your Gravity Forms.

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | An overview of files in this plugin; executable files are not allowed
There were no executable files found in this plugin1,157 lines of code in 9 files:
LanguageFilesBlank linesComment linesLines of code
PHP7287206826
PO File2128208331

PHP code Passed 2 tests

Analyzing cyclomatic complexity and code structure
All good! No complexity issues found
Cyclomatic complexity
Average complexity per logical line of code0.37
Average class complexity15.50
▷ Minimum class complexity2.00
▷ Maximum class complexity34.00
Average method complexity3.00
▷ Minimum method complexity1.00
▷ Maximum method complexity23.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes4
▷ Abstract classes00.00%
▷ Concrete classes4100.00%
▷ Final classes00.00%
Methods29
▷ Static methods1034.48%
▷ Public methods2793.10%
▷ Protected methods00.00%
▷ Private methods26.90%
Functions12
▷ Named functions1083.33%
▷ Anonymous functions216.67%
Constants1
▷ Global constants1100.00%
▷ Class constants00.00%
▷ Public constants00.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
6 PNG files occupy 0.01MB with 0.00MB in potential savings
Potential savings
Compression of 5 random PNG files using pngquant
FileSize - originalSize - compressedSavings
images/active0.png0.65KB0.61KB▼ 5.56%
images/stop.png0.68KB0.78KB0.00%
images/tick.png0.52KB0.52KB0.00%
images/remove.png3.32KB0.62KB▼ 81.33%
images/active1.png0.71KB0.63KB▼ 11.28%