77% power-forms-builder

Code Review | PowerFormBuilder - Contact Form Database Manager for WordPress

WordPress plugin PowerFormBuilder - Contact Form Database Manager for WordPress scored77%from 54 tests.

About plugin

  • Plugin page: power-forms-builder
  • Plugin version: 1.0.6
  • PHP compatiblity: 5.6+
  • PHP version: 7.4.16
  • WordPress compatibility: 4.5-5.1.1
  • WordPress version: 6.3.1
  • First release: Apr 2, 2018
  • Latest release: Apr 9, 2019
  • Number of updates: 30
  • Update frequency: every 12.6 days
  • Top authors: inornet3000x (100%)

Code review

54 tests

User reviews

2 reviews

Install metrics

30+ active /1,928 total downloads

Benchmarks

Plugin footprint 83% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | All plugins must install correctly, without throwing any errors, warnings, or notices
Install script ran successfully

Server metrics [RAM: ▲0.11MB] [CPU: ▼0.28ms] Passed 4 tests

Server-side resources used by PowerFormBuilder - Contact Form Database Manager for WordPress
This plugin does not affect your website's performance
PageMemory (MB)CPU Time (ms)
Home /3.57 ▲0.1141.05 ▼3.12
Dashboard /wp-admin3.40 ▲0.0952.65 ▲2.80
Posts /wp-admin/edit.php3.51 ▲0.1648.68 ▲1.53
Add New Post /wp-admin/post-new.php6.01 ▲0.12107.65 ▲4.92
Media Library /wp-admin/upload.php3.32 ▲0.0934.72 ▼2.32
GDPR Delete Requests /wp-admin/admin.php?page=power-form-gdpr-delete3.2932.36
Settings /wp-admin/edit.php?post_type=powerform&page=power-form-settings3.4047.20
All Forms /wp-admin/edit.php?post_type=powerform3.4240.66
Add New /wp-admin/post-new.php?post_type=powerform3.7165.75
Entries /wp-admin/edit.php?post_type=powerform&page=power-form-entries3.3033.37
Requests /wp-admin/admin.php?page=power-form-gdpr-requests3.2934.67

Server storage [IO: ▲3.87MB] [DB: ▲0.01MB] Passed 3 tests

Input-output and database impact of this plugin
No storage issues were detected
Filesystem: 229 new files
Database: 4 new tables, 18 new options
New tables
wp_wpf_entries
wp_wpf_gdpr_requested_data
wp_wpf_entry_meta
wp_wpf_gdpr_delete_data
New WordPress options
widget_recent-posts
opt-form-secret-key
opt-form-sucess-message
opt-form-gdpr-form-checkbox-text
power_form_builtin_template
opt-form-gdpr-checkbox-text
opt-form-error-message
opt-form-site-key
opt-form-submit
opt-form-page-id
...

Browser metrics Passed 4 tests

An overview of browser requirements for PowerFormBuilder - Contact Form Database Manager for WordPress
This plugin has a minimal impact on browser resources
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,971 ▲23614.14 ▼0.2413.23 ▲11.2243.28 ▼8.52
Dashboard /wp-admin2,253 ▲654.89 ▼1.02108.56 ▲1.3750.88 ▲8.80
Posts /wp-admin/edit.php2,139 ▲502.01 ▲0.0239.99 ▲0.5836.92 ▲2.04
Add New Post /wp-admin/post-new.php1,554 ▲3523.62 ▲0.41645.05 ▼28.8856.29 ▲0.63
Media Library /wp-admin/upload.php1,435 ▲474.31 ▲0.1499.53 ▲0.3143.11 ▼0.16
GDPR Delete Requests /wp-admin/admin.php?page=power-form-gdpr-delete1,0362.0324.4327.84
Settings /wp-admin/edit.php?post_type=powerform&page=power-form-settings1,9896.24151.30108.51
All Forms /wp-admin/edit.php?post_type=powerform1,6982.6437.6128.48
Add New /wp-admin/post-new.php?post_type=powerform3,0206.71181.9073.57
Entries /wp-admin/edit.php?post_type=powerform&page=power-form-entries1,1422.2634.1638.45
Requests /wp-admin/admin.php?page=power-form-gdpr-requests1,0322.0625.2230.35

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
It is recommended to fix the following
  • This plugin does not fully uninstall, leaving 6 options in the database
    • widget_recent-posts
    • can_compress_scripts
    • widget_theysaidso_widget
    • widget_recent-comments
    • db_upgraded
    • theysaidso_admin_options

Smoke tests 50% from 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | This is a shallow check for server-side errors
Even though no errors were found, this is by no means 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
  • 5× PHP files output non-empty strings when accessed directly via GET requests:
    • > /wp-content/plugins/power-forms-builder/admin/partials/power-forms-admin-display.php
    • > /wp-content/plugins/power-forms-builder/public/includes/user-email-template.php
    • > /wp-content/plugins/power-forms-builder/public/includes/admin-email-template.php
    • > /wp-content/plugins/power-forms-builder/public/partials/power-forms-public-display.php
    • > /wp-content/plugins/power-forms-builder/public/includes/power-forms-gdpr-request-data-view.php
  • 40× 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/power-forms-builder/admin/partials/power-forms-details-modal.php:12
    • > PHP Fatal error
      Uncaught Error: Call to undefined function site_url() in wp-content/plugins/power-forms-builder/admin/partials/power-forms-admin-entry-detail.php:32
    • > PHP Notice
      Undefined variable: array in wp-content/plugins/power-forms-builder/public/includes/user-email-template.php on line 81
    • > PHP Fatal error
      require_once(): Failed opening required 'ABSPATHwp-admin/includes/class-wp-list-table.php' (include_path='.:/usr/share/php') in wp-content/plugins/power-forms-builder/admin/includes/class-power-forms-entries.php on line 22
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_action() in wp-content/plugins/power-forms-builder/admin/includes/class-power-forms-admin-post-type.php:34
    • > PHP Notice
      Undefined variable: emailResults in wp-content/plugins/power-forms-builder/public/includes/power-forms-gdpr-request-data-view.php on line 41
    • > PHP Warning
      Use of undefined constant ABSPATH - assumed 'ABSPATH' (this will throw an Error in a future version of PHP) in wp-content/plugins/power-forms-builder/admin/includes/class-power-forms-gdpr-requests.php on line 22
    • > PHP Fatal error
      Uncaught Error: Call to undefined function _x() in wp-content/plugins/power-forms-builder/admin/partials/power-forms-admin-display-post-type.php:24
    • > PHP Fatal error
      Uncaught Error: Call to undefined function get_post_meta() in wp-content/plugins/power-forms-builder/admin/partials/power-forms-admin-display-form-stop.php:24
    • > PHP Notice
      Undefined variable: res in wp-content/plugins/power-forms-builder/public/includes/admin-email-template.php on line 81

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 83% from 29 tests

readme.txt 88% from 16 tests

Often overlooked, readme.txt is one of the most important files in your plugin
These attributes need to be fixed:
  • Tags: Please reduce the number of tags, currently 26 tag instead of maximum 10
  • Screenshots: These screenshots lack descriptions #10, #11 in power-forms-builder/assets to your readme.txt
The official readme.txt might help

power-forms-builder/power-forms.php 77% from 13 tests

Analyzing the main PHP file in "PowerFormBuilder - Contact Form Database Manager for WordPress" version 1.0.6
Please make the necessary changes and fix the following:
  • Main file name: It is recommended to name the main PHP file as the plugin slug ("power-forms-builder.php" instead of "power-forms.php")
  • Description: The description should be shorter than 140 characters (currently 298 characters long)
  • Text Domain: The text domain is optional since WordPress version 4.6; if you do specify it, it must be the same as the plugin slug

Code Analysis 97% from 3 tests

File types Passed 1 test

🔸 Test weight: 35 | This is an overview of file extensions present in this plugin and a short test that no dangerous files are bundled with this plugin
No dangerous file extensions were detected23,408 lines of code in 208 files:
LanguageFilesBlank linesComment linesLines of code
CSS211,33127313,199
PHP417062,2964,507
JavaScript1423206833,762
PO File45605481,940

PHP code 50% from 2 tests

A brief analysis of cyclomatic complexity and code structure for this plugin
Please fix the following
  • Method cyclomatic complexity has to be reduced to less than 100 (currently 129)
Cyclomatic complexity
Average complexity per logical line of code0.38
Average class complexity28.82
▷ Minimum class complexity1.00
▷ Maximum class complexity167.00
Average method complexity4.35
▷ Minimum method complexity1.00
▷ Maximum method complexity129.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes17
▷ Abstract classes00.00%
▷ Concrete classes17100.00%
▷ Final classes00.00%
Methods144
▷ Static methods149.72%
▷ Public methods13694.44%
▷ Protected methods00.00%
▷ Private methods85.56%
Functions19
▷ Named functions19100.00%
▷ Anonymous functions00.00%
Constants7
▷ Global constants7100.00%
▷ Class constants00.00%
▷ Public constants00.00%

Plugin size Passed 2 tests

Image compression Passed 2 tests

All PNG images should be compressed to minimize bandwidth usage for end users
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
admin/images/logo.png6.85KB4.19KB▼ 38.78%