67% wp-tools-gravity-forms-divi-module

Code Review | WP Tools Gravity Forms Divi Module

WordPress plugin WP Tools Gravity Forms Divi Module scored67%from 54 tests.

About plugin

  • Plugin page: wp-tools-gravity-...
  • Plugin version: 8.1.1
  • PHP compatiblity: 7.2.5+
  • PHP version: 7.4.16
  • WordPress compatibility: 4.5-6.4
  • WordPress version: 6.3.1
  • First release: Oct 24, 2019
  • Latest release: Nov 8, 2023
  • Number of updates: 31
  • Update frequency: every 48.2 days
  • Top authors: wpt00ls (100%)

Code review

54 tests

User reviews

6 reviews

Install metrics

3,000+ active /40,480 total downloads

Benchmarks

Plugin footprint 65% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | It is important to correctly install your plugin, without throwing errors or notices
This plugin's installer ran successfully

Server metrics [RAM: ▲5.01MB] [CPU: ▲26.30ms] 75% from 4 tests

An overview of server-side resources used by WP Tools Gravity Forms Divi Module
Please have a look at the following items
  • Extra RAM: Extra memory usage should kept under 5MB (currently 5.01MB on /wp-admin/admin.php?page=freemius)
PageMemory (MB)CPU Time (ms)
Home /8.88 ▲5.4263.38 ▲21.12
Dashboard /wp-admin8.90 ▲5.6074.86 ▲24.91
Posts /wp-admin/edit.php8.90 ▲5.5579.97 ▲33.57
Add New Post /wp-admin/post-new.php9.35 ▲3.46122.22 ▲25.59
Media Library /wp-admin/upload.php8.90 ▲5.6769.45 ▲34.59
Gravity Form Divi /wp-admin/admin.php?page=wp-tools-gravity-forms-divi-module8.9064.92
Freemius Debug [v.2.5.12] /wp-admin/admin.php?page=freemius8.9057.04

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

Input-output and database impact of this plugin
No storage issues were detected
Filesystem: 234 new files
Database: no new tables, 9 new options
New WordPress options
db_upgraded
theysaidso_admin_options
widget_recent-comments
can_compress_scripts
fs_accounts
widget_theysaidso_widget
widget_recent-posts
fs_active_plugins
fs_debug_mode

Browser metrics Passed 4 tests

Checking browser requirements for WP Tools Gravity Forms Divi Module
There were no issues detected in relation to browser resource usage
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,807 ▲2014.71 ▲0.351.68 ▼0.3228.42 ▼16.84
Dashboard /wp-admin2,209 ▲295.53 ▼0.09100.37 ▲7.4948.25 ▲11.29
Posts /wp-admin/edit.php2,121 ▲182.02 ▲0.0641.79 ▲0.5438.68 ▲5.12
Add New Post /wp-admin/post-new.php1,531 ▲521.70 ▼1.57687.23 ▲53.0857.63 ▲7.46
Media Library /wp-admin/upload.php1,420 ▲234.25 ▼0.03101.65 ▼0.1848.29 ▲3.46
Gravity Form Divi /wp-admin/admin.php?page=wp-tools-gravity-forms-divi-module9791.6627.4162.22
Freemius Debug [v.2.5.12] /wp-admin/admin.php?page=freemius1,0821.6624.2526.90

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

🔸 Tests weight: 35 | Checking the uninstaller removed all traces of the plugin
Please fix the following items
  • This plugin cannot be uninstalled
    • > Notice in wp-content/plugins/wp-tools-gravity-forms-divi-module/freemius/includes/class-freemius.php+8515
    Undefined property: stdClass::$plugins
  • The uninstall procedure has failed, leaving 9 options in the database
    • widget_theysaidso_widget
    • theysaidso_admin_options
    • can_compress_scripts
    • widget_recent-comments
    • fs_debug_mode
    • fs_active_plugins
    • db_upgraded
    • fs_accounts
    • widget_recent-posts

Smoke tests 50% from 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | This is a shallow check for server-side errors
Everything seems fine, however this is by no means an exhaustive test

SRP 0% from 2 tests

🔹 Tests weight: 20 | A shallow check of the single-responsibility principle; PHP files should perform no action - including output of placeholder text - and trigger no errors when accessed directly
Almost there! Just fix the following items
  • 1× PHP files perform the action of outputting non-empty strings when accessed directly:
    • > /wp-content/plugins/wp-tools-gravity-forms-divi-module/resources/views/sub_menu.php
  • 13× GET requests to PHP files trigger server-side errors or Error 500 responses (only 10 are shown):
    • > PHP Fatal error
      Uncaught Error: Call to undefined function esc_attr() in wp-content/plugins/wp-tools-gravity-forms-divi-module/resources/views/et_pb_wpt_gravityform.php:1
    • > PHP Fatal error
      Uncaught Error: Interface 'WPTools\\Psr\\Container\\ContainerInterface' not found in wp-content/plugins/wp-tools-gravity-forms-divi-module/vendor/wpt00ls/pimple/src/Pimple/Psr11/Container.php:37
    • > PHP Fatal error
      Uncaught Error: Class 'ET_Builder_Module_Field_Base' not found in wp-content/plugins/wp-tools-gravity-forms-divi-module/src/Divi/ET_Builder_Module_Field_Border.php:9
    • > PHP Fatal error
      Uncaught Error: Interface 'WPTools\\Psr\\Container\\ContainerInterface' not found in wp-content/plugins/wp-tools-gravity-forms-divi-module/vendor/wpt00ls/pimple/src/Pimple/Psr11/ServiceLocator.php:38
    • > PHP Fatal error
      Uncaught Error: Interface 'WPTools\\Psr\\Container\\ContainerExceptionInterface' not found in wp-content/plugins/wp-tools-gravity-forms-divi-module/vendor/wpt00ls/pimple/src/Pimple/Exception/ExpectedInvokableException.php:36
    • > PHP Fatal error
      Uncaught Error: Interface 'WPTools\\Psr\\Container\otFoundExceptionInterface' not found in wp-content/plugins/wp-tools-gravity-forms-divi-module/vendor/wpt00ls/pimple/src/Pimple/Exception/UnknownIdentifierException.php:36
    • > PHP Fatal error
      Uncaught Error: Class 'DiviExtension' not found in wp-content/plugins/wp-tools-gravity-forms-divi-module/includes/modules/GravityFormExtension.php:6
    • > PHP Fatal error
      Uncaught Error: Interface 'WPTools\\Psr\\Container\\ContainerExceptionInterface' not found in wp-content/plugins/wp-tools-gravity-forms-divi-module/vendor/wpt00ls/pimple/src/Pimple/Exception/FrozenServiceException.php:36
    • > PHP Fatal error
      Uncaught Error: Class 'WPTools\\Pimple\\Container' not found in wp-content/plugins/wp-tools-gravity-forms-divi-module/src/Loader.php:9
    • > PHP Fatal error
      Uncaught Error: Class 'ET_Builder_Module' not found in wp-content/plugins/wp-tools-gravity-forms-divi-module/includes/modules/GravityFormModule/GravityFormModule.php:10

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 issues were found

Optimizations

Plugin configuration 93% from 29 tests

readme.txt Passed 16 tests

The readme.txt file is an important file in your plugin as it is parsed by WordPress.org to prepare the public listing of your plugin
6 plugin tags: gravityforms, gravity forms divi, divi, gravity forms, style gravityforms...

wp-tools-gravity-forms-divi-module/wp-tools-gravity-forms-divi-module.php 85% from 13 tests

"WP Tools Gravity Forms Divi Module" version 8.1.1's primary PHP file adds more information about the plugin and serves as the entry point for WordPress
The following require your attention:
  • Description: Please keep the plugin description shorter than 140 characters (currently 204 characters long)
  • Domain Path: The domain path folder was not found ("/languages")

Code Analysis 97% from 3 tests

File types Passed 1 test

🔸 Test weight: 35 | There should be no dangerous file extensions present in any WordPress plugin
No dangerous file extensions were detected35,824 lines of code in 179 files:
LanguageFilesBlank linesComment linesLines of code
PHP1528,37118,32535,248
JavaScript73961203
JSON300186
reStructuredText19613997
CSS1412166
XML12016
Markdown1508

PHP code 50% from 2 tests

Analyzing logical lines of code, cyclomatic complexity, and other code metrics
These items need your attention
  • Cyclomatic complexity of classes should be reduced to less than 1000 (currently 3,088)
Cyclomatic complexity
Average complexity per logical line of code0.63
Average class complexity65.05
▷ Minimum class complexity1.00
▷ Maximum class complexity3,088.00
Average method complexity4.42
▷ Minimum method complexity1.00
▷ Maximum method complexity94.00
Code structure
Namespaces12
Interfaces4
Traits0
Classes69
▷ Abstract classes22.90%
▷ Concrete classes6797.10%
▷ Final classes22.99%
Methods1,400
▷ Static methods21815.57%
▷ Public methods1,00771.93%
▷ Protected methods171.21%
▷ Private methods37626.86%
Functions112
▷ Named functions9988.39%
▷ Anonymous functions1311.61%
Constants145
▷ Global constants9867.59%
▷ Class constants4732.41%
▷ Public constants47100.00%

Plugin size Passed 2 tests

Image compression Passed 2 tests

All PNG images should be compressed to minimize bandwidth usage for end users
3 PNG files occupy 0.02MB with 0.01MB in potential savings
Potential savings
Compression of 3 random PNG files using pngquant
FileSize - originalSize - compressedSavings
freemius/assets/img/theme-icon.png10.97KB5.78KB▼ 47.37%
freemius/assets/img/plugin-icon.png9.16KB5.26KB▼ 42.58%
freemius/assets/img/wp-tools-gravity-forms-divi-module.png1.37KB0.23KB▼ 82.93%