62% flow-fields

Code Review | Flow Fields

WordPress plugin Flow Fields scored62%from 54 tests.

About plugin

  • Plugin page: flow-fields
  • Plugin version: 1.1.4
  • PHP version: 7.4.16
  • WordPress compatibility: 5.0-6.2.2
  • WordPress version: 6.3.1
  • First release: Jun 9, 2023
  • Latest release: Jul 11, 2023
  • Number of updates: 16
  • Update frequency: every 6.4 days
  • Top authors: wojciechborowicz (100%)

Code review

54 tests

User reviews

1 review

Install metrics

10+ active /335 total downloads

Benchmarks

Plugin footprint 65% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | The install procedure must perform silently
Installer ran successfully

Server metrics [RAM: ▲0.54MB] [CPU: ▲4.97ms] Passed 4 tests

A check of server-side resources used by Flow Fields
This plugin does not affect your website's performance
PageMemory (MB)CPU Time (ms)
Home /3.96 ▲0.5040.83 ▼5.37
Dashboard /wp-admin3.91 ▲0.6057.46 ▲9.50
Posts /wp-admin/edit.php3.95 ▲0.6053.37 ▲6.83
Add New Post /wp-admin/post-new.php6.42 ▲0.53100.67 ▲11.34
Media Library /wp-admin/upload.php3.74 ▲0.5140.82 ▲8.92
Flow Fields /wp-admin/admin.php?page=flow_field_boxes3.7440.95
Report a Bug /wp-admin/admin.php?page=report_bug3.7443.15
Custom Post Types /wp-admin/admin.php?page=flow_cpts3.7441.68
Tools /wp-admin/admin.php?page=flow_tools3.7443.37
Taxonomies /wp-admin/admin.php?page=flow_taxonomies3.7440.93
Settings /wp-admin/admin.php?page=flow_field_boxes_options3.7135.39

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

A short overview of filesystem and database impact
This plugin was installed successfully
Filesystem: 22 new files
Database: 4 new tables, 7 new options
New tables
wp_flow_fields
wp_flow_taxonomies
wp_flow_boxes
wp_flow_custom_post_types
New WordPress options
widget_recent-comments
db_upgraded
theysaidso_admin_options
flow_fields_db_version
widget_theysaidso_widget
widget_recent-posts
can_compress_scripts

Browser metrics Passed 4 tests

A check of browser resources used by Flow Fields
This plugin has a minimal impact on browser resources
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /3,007 ▲27215.38 ▲1.011.66 ▼0.5138.80 ▼14.67
Dashboard /wp-admin2,413 ▲2226.93 ▲1.06144.34 ▲30.3242.68 ▼0.62
Posts /wp-admin/edit.php2,322 ▲2363.54 ▲1.5459.05 ▲22.9930.41 ▼2.10
Add New Post /wp-admin/post-new.php1,584 ▲5118.62 ▼4.42577.60 ▼96.4132.09 ▼26.96
Media Library /wp-admin/upload.php1,455 ▲734.71 ▲0.5189.62 ▼11.7540.55 ▼2.58
Flow Fields /wp-admin/admin.php?page=flow_field_boxes1,1013.5947.5171.87
Report a Bug /wp-admin/admin.php?page=report_bug1,0563.5047.3854.90
Custom Post Types /wp-admin/admin.php?page=flow_cpts1,0843.6248.6371.69
Tools /wp-admin/admin.php?page=flow_tools1,0853.5744.2183.48
Taxonomies /wp-admin/admin.php?page=flow_taxonomies1,0773.7245.6075.73
Settings /wp-admin/admin.php?page=flow_field_boxes_options1,1733.9353.5094.24

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

🔸 Tests weight: 35 | It is important to correctly uninstall your plugin, without leaving any traces
These items require your attention
  • The uninstall procedure failed, leaving 4 tables in the database
    • wp_flow_boxes
    • wp_flow_taxonomies
    • wp_flow_custom_post_types
    • wp_flow_fields
  • This plugin did not uninstall successfully, leaving 7 options in the database
    • db_upgraded
    • theysaidso_admin_options
    • can_compress_scripts
    • flow_fields_db_version
    • widget_recent-comments
    • widget_recent-posts
    • widget_theysaidso_widget

Smoke tests 25% from 4 tests

Server-side errors 0% from 1 test

🔹 Test weight: 20 | This is a short smoke test looking for server-side errors
Almost there, just fix the following server-side errors
    • > GET request to /wp-admin/admin.php?page=flow_field_boxes_options
    • > Warning in wp-content/plugins/flow-fields/includes/templates/create_admin_pages.php+210
    array_key_exists() expects parameter 2 to be array, bool given

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
Almost there! Just fix the following items
  • 9× PHP files trigger server-side errors or warnings when accessed directly:
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_filter() in wp-content/plugins/flow-fields/includes/fields/flow_fields_for_bricks.php:8
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_action() in wp-content/plugins/flow-fields/includes/fields/flow_fields_output.php:29
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_action() in wp-content/plugins/flow-fields/includes/fields/flow_fields_manage.php:76
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_action() in wp-content/plugins/flow-fields/includes/taxonomies/flow_tax.php:265
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_action() in wp-content/plugins/flow-fields/includes/cpt/flow_cpt_admin.php:519
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_action() in wp-content/plugins/flow-fields/includes/templates/create_admin_pages.php:78
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_action() in wp-content/plugins/flow-fields/includes/templates/admin_assets.php:20
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_action() in wp-content/plugins/flow-fields/flow-fields.php:17
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_shortcode() in wp-content/plugins/flow-fields/includes/general_functions.php:149

User-side errors 0% from 1 test

🔹 Test weight: 20 | This is a smoke test targeting browser errors/issues
Please fix the following browser errors
  • 6 occurences, only the last one shown
    • > GET request to /wp-admin/admin.php?page=flow_field_boxes_options
    • > Deprecation (warning) in unknown
    /wp-admin/load-scripts.php?c=0&load%5Bchunk_0%5D=jquery-core,jquery-migrate,utils,moxiejs,plupload&ver=6.3.1 1 Listener added for a synchronous 'DOMSubtreeModified' DOM Mutation Event. This event type is deprecated (https://w3c.github.io/uievents/#legacy-event-types) and work is underway to remove it from this browser. Usage of this event listener will cause performance issues today, and represents a risk of future incompatibility. Consider using MutationObserver instead.

Optimizations

Plugin configuration 97% from 29 tests

readme.txt 94% from 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
These attributes need your attention:
  • Screenshots: Please add descriptions for these screenshots #1, #2, #3 in flow-fields/assets to your readme.txt
You can look at the official readme.txt

flow-fields/flow-fields.php Passed 13 tests

"Flow Fields" version 1.1.4's primary PHP file adds more information about the plugin and serves as the entry point for WordPress
35 characters long description:
Manage fields and custom post types

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | A short review of files and their extensions; it is not recommended to include executable files
There were no executable files found in this plugin5,443 lines of code in 19 files:
LanguageFilesBlank linesComment linesLines of code
PHP125682383,582
CSS15117939
JavaScript6196101922

PHP code Passed 2 tests

A brief analysis of cyclomatic complexity and code structure for this plugin
This plugin has no cyclomatic complexity issues
Cyclomatic complexity
Average complexity per logical line of code0.40
Average class complexity0.00
▷ Minimum class complexity0.00
▷ Maximum class complexity0.00
Average method complexity0.00
▷ Minimum method complexity0.00
▷ Maximum method complexity0.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes0
▷ Abstract classes00.00%
▷ Concrete classes00.00%
▷ Final classes00.00%
Methods0
▷ Static methods00.00%
▷ Public methods00.00%
▷ Protected methods00.00%
▷ Private methods00.00%
Functions68
▷ Named functions6494.12%
▷ Anonymous functions45.88%
Constants0
▷ Global constants00.00%
▷ Class constants00.00%
▷ Public constants00.00%

Plugin size Passed 2 tests

Image compression Passed 2 tests

PNG files should be compressed to save space and minimize bandwidth usage
PNG images were not found in this plugin