84% faq-block-for-gutenberg

Code Review | FAQ Block For Gutenberg

WordPress plugin FAQ Block For Gutenberg scored84%from 54 tests.

About plugin

  • Plugin page: faq-block-for-gut...
  • Plugin version: 2.5
  • PHP compatiblity: 7.2+
  • PHP version: 7.4.16
  • WordPress compatibility: 5.0-6.3
  • WordPress version: 6.3.1
  • First release: Feb 24, 2018
  • Latest release: Oct 31, 2023
  • Number of updates: 39
  • Update frequency: every 53.2 days
  • Top authors: dilipbheda (100%)Otto42 (5.13%)

Code review

54 tests

User reviews

5 reviews

Install metrics

900+ active /11,900 total downloads

Benchmarks

Plugin footprint 83% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | Verifying that this plugin installs correctly without errors
The plugin installed successfully, without throwing any errors or notices

Server metrics [RAM: ▲0.02MB] [CPU: ▼6.68ms] Passed 4 tests

Server-side resources used by FAQ Block For Gutenberg
This plugin does not affect your website's performance
PageMemory (MB)CPU Time (ms)
Home /3.51 ▲0.0439.73 ▼2.00
Dashboard /wp-admin3.34 ▼0.0146.61 ▼17.73
Posts /wp-admin/edit.php3.39 ▲0.0346.21 ▼5.48
Add New Post /wp-admin/post-new.php5.92 ▲0.0392.24 ▲0.48
Media Library /wp-admin/upload.php3.26 ▲0.0334.61 ▼1.51

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

Filesystem and database footprint
No storage issues were detected
Filesystem: 9 new files
Database: no new tables, 6 new options
New WordPress options
can_compress_scripts
widget_recent-comments
widget_recent-posts
theysaidso_admin_options
db_upgraded
widget_theysaidso_widget

Browser metrics Passed 4 tests

FAQ Block For Gutenberg: an overview of browser usage
Normal browser usage
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,872 ▲12613.47 ▼0.898.60 ▲6.9143.29 ▼0.97
Dashboard /wp-admin2,195 ▲185.61 ▼0.0593.56 ▲5.4742.13 ▲3.07
Posts /wp-admin/edit.php2,100 ▼02.01 ▼0.0035.79 ▼2.4635.94 ▲3.96
Add New Post /wp-admin/post-new.php6,200 ▲4,67419.30 ▼3.74837.55 ▲119.0736.80 ▼23.89
Media Library /wp-admin/upload.php1,394 ▼64.18 ▼0.10102.40 ▼3.3444.91 ▲1.16

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
  • Zombie WordPress options were found after uninstall: 6 options
    • widget_recent-posts
    • widget_theysaidso_widget
    • theysaidso_admin_options
    • can_compress_scripts
    • db_upgraded
    • widget_recent-comments

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)
Good news, no errors were detected

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
Please take a closer look at the following
  • 1× GET requests to PHP files trigger server-side errors or Error 500 responses:
    • > PHP Fatal error
      Uncaught Error: Call to undefined function plugin_dir_path() in wp-content/plugins/faq-block-for-gutenberg/faq-block-for-gutenberg.php:19

User-side errors Passed 1 test

🔹 Test weight: 20 | This is just a short smoke test looking for browser issues
No browser errors were detected

Optimizations

Plugin configuration Passed 29 tests

readme.txt Passed 16 tests

The readme.txt file describes your plugin functionality and requirements and it is parsed to prepare the your plugin's listing
5 plugin tags: gutenberg faq, faq block, blocks, editor, faq

faq-block-for-gutenberg/faq-block-for-gutenberg.php Passed 13 tests

This is the main PHP file of "FAQ Block For Gutenberg" version 2.5, providing information about the plugin in the header fields and serving as the principal entry point to the plugin's functions
91 characters long description:
This plugin provides a quick and easy way to add FAQ's block using Gutenberg visual editor.

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | An overview of files in this plugin; executable files are not allowed
There were no executable files found in this plugin121 lines of code in 7 files:
LanguageFilesBlank linesComment linesLines of code
PHP41177118
JavaScript2002
CSS1001

PHP code Passed 2 tests

This is a very shot review of cyclomatic complexity and code structure
Great job! No cyclomatic complexity issues were detected in this plugin
Cyclomatic complexity
Average complexity per logical line of code0.34
Average class complexity11.00
▷ Minimum class complexity11.00
▷ Maximum class complexity11.00
Average method complexity2.67
▷ Minimum method complexity1.00
▷ Maximum method complexity5.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes1
▷ Abstract classes00.00%
▷ Concrete classes1100.00%
▷ Final classes00.00%
Methods6
▷ Static methods00.00%
▷ Public methods583.33%
▷ Protected methods00.00%
▷ Private methods116.67%
Functions4
▷ Named functions4100.00%
▷ Anonymous functions00.00%
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
No PNG images were found in this plugin