78% acf-flexible-layouts-manager

Code Review | ACF Flexible Layouts Manager

WordPress plugin ACF Flexible Layouts Manager scored78%from 54 tests.

About plugin

  • Plugin page: acf-flexible-layo...
  • Plugin version: 1.1.6
  • PHP compatiblity: 5.4+
  • PHP version: 7.4.16
  • WordPress compatibility: 4.0-5.2.2
  • WordPress version: 6.3.1
  • First release: Apr 11, 2018
  • Latest release: Jul 12, 2019
  • Number of updates: 29
  • Update frequency: every 15.8 days
  • Top authors: valentinpellegrin (100%)

Code review

54 tests

User reviews

6 reviews

Install metrics

2,000+ active /12,401 total downloads

Benchmarks

Plugin footprint 83% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | The install procedure must perform silently
The plugin installed successfully, without throwing any errors or notices

Server metrics [RAM: ▲0.01MB] [CPU: ▼5.01ms] Passed 4 tests

An overview of server-side resources used by ACF Flexible Layouts Manager
This plugin has minimal impact on server resources
PageMemory (MB)CPU Time (ms)
Home /3.48 ▲0.0141.65 ▲1.47
Dashboard /wp-admin3.32 ▲0.0248.09 ▼4.55
Posts /wp-admin/edit.php3.37 ▲0.0149.04 ▼3.48
Add New Post /wp-admin/post-new.php5.90 ▲0.0187.02 ▼13.46
Media Library /wp-admin/upload.php3.24 ▲0.0137.56 ▲1.84

Server storage [IO: ▲0.05MB] [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
widget_recent-posts
widget_recent-comments
theysaidso_admin_options
can_compress_scripts
db_upgraded
widget_theysaidso_widget

Browser metrics Passed 4 tests

This is an overview of browser requirements for ACF Flexible Layouts Manager
There were no issues detected in relation to browser resource usage
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,815 ▲5413.23 ▼1.071.73 ▲0.1640.85 ▼2.83
Dashboard /wp-admin2,215 ▲155.84 ▼0.02101.92 ▲1.0141.50 ▼0.71
Posts /wp-admin/edit.php2,103 ▼02.04 ▲0.0541.76 ▲3.9536.83 ▼0.92
Add New Post /wp-admin/post-new.php1,550 ▲923.05 ▲4.80649.23 ▲28.0967.02 ▲6.44
Media Library /wp-admin/upload.php1,400 ▼34.22 ▲0.01105.75 ▲4.4148.77 ▲6.82

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

🔸 Tests weight: 35 | Checking the uninstaller removed all traces of the plugin
It is recommended to fix the following
  • The uninstall procedure has failed, leaving 6 options in the database
    • widget_recent-posts
    • widget_theysaidso_widget
    • widget_recent-comments
    • can_compress_scripts
    • db_upgraded
    • theysaidso_admin_options

Smoke tests 50% from 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | A shallow check that no server-side errors were triggered
The smoke test was a success, however most plugin functionality was not tested

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
Please fix the following items
  • 1× GET requests to PHP files return non-empty strings:
    • > /wp-content/plugins/acf-flexible-layouts-manager/acf-flexible-layouts-manager.php
  • 8× GET requests to PHP files have triggered server-side errors or warnings:
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_action() in wp-content/plugins/acf-flexible-layouts-manager/includes/languages.php:3
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_filter() in wp-content/plugins/acf-flexible-layouts-manager/helpers/add-button.php:39
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_action() in wp-content/plugins/acf-flexible-layouts-manager/includes/paste.php:3
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_action() in wp-content/plugins/acf-flexible-layouts-manager/includes/ajax/ajax-duplicate.php:2
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_action() in wp-content/plugins/acf-flexible-layouts-manager/includes/ajax/ajax-select.php:2
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_action() in wp-content/plugins/acf-flexible-layouts-manager/includes/select.php:3
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_action() in wp-content/plugins/acf-flexible-layouts-manager/includes/ajax/ajax-copy.php:2
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_action() in wp-content/plugins/acf-flexible-layouts-manager/includes/ajax/ajax-paste.php:2

User-side errors Passed 1 test

🔹 Test weight: 20 | This is just a short smoke test looking for browser issues
Everything seems fine on the user side

Optimizations

Plugin configuration 97% from 29 tests

readme.txt 94% from 16 tests

The readme.txt file describes your plugin functionality and requirements and it is parsed to prepare the your plugin's listing
Please fix the following attributes:
  • Donate link: Invalid URI found ("")
You can look at the official readme.txt

acf-flexible-layouts-manager/acf-flexible-layouts-manager.php Passed 13 tests

Analyzing the main PHP file in "ACF Flexible Layouts Manager" version 1.1.6
86 characters long description:
Add "Copy", "Duplicate", "Import" & "Paste" options for layout in ACF Flexible Content

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | Executable files are not allowed as they can serve as attack vectors
There were no executable files found in this plugin760 lines of code in 17 files:
LanguageFilesBlank linesComment linesLines of code
JavaScript611782343
PHP99931279
PO File1222274
CSS10064

PHP code Passed 2 tests

This plugin's cyclomatic complexity and code structure detailed below
All good! No complexity issues found
Cyclomatic complexity
Average complexity per logical line of code0.65
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%
Functions12
▷ Named functions12100.00%
▷ Anonymous functions00.00%
Constants2
▷ Global constants2100.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
There are no PNG files in this plugin