83% gravity-forms-mad-mimi

Code Review | Gravity Forms Mad Mimi Add-on

WordPress plugin Gravity Forms Mad Mimi Add-on scored83%from 54 tests.

About plugin

  • Plugin page: gravity-forms-mad...
  • Plugin version: 2.0.2
  • PHP version: 7.4.16
  • WordPress compatibility: 3.2-3.8.1
  • WordPress version: 6.3.1
  • First release: Jul 28, 2011
  • Latest release: Feb 28, 2014
  • Number of updates: 30
  • Update frequency: every 31.5 days
  • Top authors: katzwebdesign (100%)

Code review

54 tests

User reviews

3 reviews

Install metrics

20+ active /4,883 total downloads

Benchmarks

Plugin footprint 83% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | Checking the installer triggered no errors
This plugin's installer ran successfully

Server metrics [RAM: ▲0.08MB] [CPU: ▼6.36ms] Passed 4 tests

This is a short check of server-side resources used by Gravity Forms Mad Mimi Add-on
This plugin does not affect your website's performance
PageMemory (MB)CPU Time (ms)
Home /3.56 ▲0.0936.01 ▼5.12
Dashboard /wp-admin3.40 ▲0.0553.39 ▼11.12
Posts /wp-admin/edit.php3.52 ▲0.1648.22 ▲1.03
Add New Post /wp-admin/post-new.php5.98 ▲0.0990.32 ▼10.24
Media Library /wp-admin/upload.php3.33 ▲0.0940.11 ▲9.33

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

Filesystem and database footprint
There were no storage issued detected upon installing this plugin
Filesystem: 20 new files
Database: no new tables, 6 new options
New WordPress options
can_compress_scripts
theysaidso_admin_options
widget_theysaidso_widget
db_upgraded
widget_recent-comments
widget_recent-posts

Browser metrics Passed 4 tests

This is an overview of browser requirements for Gravity Forms Mad Mimi Add-on
There were no issues detected in relation to browser resource usage
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,800 ▲5413.25 ▼1.121.66 ▲0.0741.93 ▲1.87
Dashboard /wp-admin2,206 ▲185.91 ▲1.02100.93 ▼9.1238.03 ▼3.73
Posts /wp-admin/edit.php2,086 ▼32.01 ▲0.0237.62 ▼0.3531.32 ▼1.24
Add New Post /wp-admin/post-new.php1,517 ▼417.80 ▼5.18670.78 ▼12.2753.48 ▼9.93
Media Library /wp-admin/upload.php1,388 ▼04.23 ▲0.0596.94 ▼10.5344.91 ▲0.31

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

🔸 Tests weight: 35 | The uninstall procedure must remove all plugin files and extra database tables
You still need to fix the following
  • This plugin does not fully uninstall, leaving 6 options in the database
    • widget_recent-posts
    • widget_recent-comments
    • widget_theysaidso_widget
    • theysaidso_admin_options
    • can_compress_scripts
    • db_upgraded

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)
The smoke test was a success, however most plugin functionality was not tested

SRP 50% from 2 tests

🔹 Tests weight: 20 | SRP (Single-Responsibility Principle) - PHP files must act as libraries and never output text or perform any action when accessed directly in a browser
Please fix the following
  • 3× PHP files trigger errors when accessed directly with GET requests:
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_action() in wp-content/plugins/gravity-forms-mad-mimi/madmimi.php:29
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_action() in wp-content/plugins/gravity-forms-mad-mimi/madmimi.beta.php:29
    • > PHP Fatal error
      Uncaught Error: Class 'MadMimi' not found in wp-content/plugins/gravity-forms-mad-mimi/lib/MadMimiSuperClass.class.php:3

User-side errors Passed 1 test

🔹 Test weight: 20 | A shallow check that no browser errors were triggered
Everything seems fine on the user side

Optimizations

Plugin configuration 90% from 29 tests

readme.txt 88% from 16 tests

The readme.txt file describes your plugin functionality and requirements and it is parsed to prepare the your plugin's listing
These attributes need to be fixed:
  • Tags: Please delete some tags, you are using 13 tag instead of maximum 10
  • Screenshots: These screenshots have no corresponding images in /assets: #1 (The Gravity Forms Mad Mimi Add-on settings page), #2 (It's easy to integrate Gravity Forms with Mad Mimi: set up a "Feed" and match up the fields you'd like sent to Mad Mimi)
You can take inspiration from this readme.txt

gravity-forms-mad-mimi/madmimi.beta.php 92% from 13 tests

This is the main PHP file of "Gravity Forms Mad Mimi Add-on" version 2.0.2, providing information about the plugin in the header fields and serving as the principal entry point to the plugin's functions
Please make the necessary changes and fix the following:
  • Main file name: Please rename the main PHP file in this plugin to the plugin slug ("gravity-forms-mad-mimi.php" instead of "madmimi.beta.php")

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | There should be no dangerous file extensions present in any WordPress plugin
Good job! No executable or dangerous file extensions detected2,550 lines of code in 8 files:
LanguageFilesBlank linesComment linesLines of code
PHP85615472,550

PHP code Passed 2 tests

Analyzing cyclomatic complexity and code structure
No complexity issues detected
Cyclomatic complexity
Average complexity per logical line of code0.51
Average class complexity72.14
▷ Minimum class complexity9.00
▷ Maximum class complexity215.00
Average method complexity4.15
▷ Minimum method complexity1.00
▷ Maximum method complexity43.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes7
▷ Abstract classes114.29%
▷ Concrete classes685.71%
▷ Final classes00.00%
Methods158
▷ Static methods4830.38%
▷ Public methods8755.06%
▷ Protected methods1710.76%
▷ Private methods5434.18%
Functions3
▷ Named functions3100.00%
▷ Anonymous functions00.00%
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
5 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/madmimi_wordpress_icon_32.png1.87KB1.49KB▼ 20.14%
images/add.png3.37KB0.66KB▼ 80.54%
images/remove.png3.32KB0.62KB▼ 81.33%
images/active1.png0.71KB0.63KB▼ 11.28%
images/active0.png0.65KB0.61KB▼ 5.56%