84% easy-accordion-free

Code Review | Easy Accordion - Best Accordion FAQ Plugin for WordPress

WordPress plugin Easy Accordion - Best Accordion FAQ Plugin for WordPress scored84%from 54 tests.

About plugin

  • Plugin page: easy-accordion-free
  • Plugin version: 2.2.5
  • PHP version: 7.4.16
  • WordPress compatibility: 4.7-6.4
  • WordPress version: 6.3.1
  • First release: Jul 31, 2014
  • Latest release: Oct 26, 2023
  • Number of updates: 88
  • Update frequency: every 38.4 days
  • Top authors: shapedplugin (61.36%)rubel_miah (37.5%)lazypersons (3.41%)

Code review

54 tests

User reviews

241 reviews

Install metrics

50,000+ active /612,293 total downloads

Benchmarks

Plugin footprint 83% from 16 tests

Installer Passed 1 test

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

Server metrics [RAM: ▲0.80MB] [CPU: ▲2.41ms] Passed 4 tests

Server-side resources used by Easy Accordion - Best Accordion FAQ Plugin for WordPress
Server-side resource usage in normal parameters
PageMemory (MB)CPU Time (ms)
Home /4.28 ▲0.8247.94 ▲7.04
Dashboard /wp-admin4.11 ▲0.8053.98 ▲6.33
Posts /wp-admin/edit.php4.16 ▲0.8049.89 ▲2.74
Add New Post /wp-admin/post-new.php6.70 ▲0.8189.43 ▼4.84
Media Library /wp-admin/upload.php4.03 ▲0.8041.96 ▲5.41
Tools /wp-admin/edit.php?post_type=sp_easy_accordion&page=eap_tools4.4647.67
Accordion Groups /wp-admin/edit.php?post_type=sp_easy_accordion4.5653.59
Add New /wp-admin/post-new.php?post_type=sp_easy_accordion4.6160.24
Help /wp-admin/edit.php?post_type=sp_easy_accordion&page=eap_help4.4644.22
Settings /wp-admin/edit.php?post_type=sp_easy_accordion&page=eap_settings4.4657.52

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

Input-output and database impact of this plugin
This plugin was installed successfully
Filesystem: 145 new files
Database: no new tables, 12 new options
New WordPress options
widget_theysaidso_widget
easy_accordion_free_first_version
can_compress_scripts
easy_accordion_free_activation_date
sp_eafree_review_notice_dismiss
widget_recent-posts
sp_eap_settings
easy_accordion_free_version
db_upgraded
widget_recent-comments
...

Browser metrics Passed 4 tests

Easy Accordion - Best Accordion FAQ Plugin for WordPress: an overview of browser usage
This plugin has a minimal impact on browser resources
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,905 ▲11914.34 ▼0.191.94 ▲0.1832.51 ▼7.57
Dashboard /wp-admin2,283 ▲1035.60 ▼0.0481.49 ▼2.5839.76 ▼3.13
Posts /wp-admin/edit.php2,192 ▲922.04 ▲0.0935.58 ▲1.2733.51 ▲1.19
Add New Post /wp-admin/post-new.php6,244 ▲4,71818.80 ▼4.49922.14 ▲259.6062.29 ▲6.92
Media Library /wp-admin/upload.php1,491 ▲914.22 ▲0.0897.41 ▲6.2143.93 ▲3.61
Tools /wp-admin/edit.php?post_type=sp_easy_accordion&page=eap_tools1,4205.6276.7141.58
Accordion Groups /wp-admin/edit.php?post_type=sp_easy_accordion1,5595.5365.5229.17
Add New /wp-admin/post-new.php?post_type=sp_easy_accordion3,7646.15103.79211.31
Help /wp-admin/edit.php?post_type=sp_easy_accordion&page=eap_help2,16811.25316.78174.13
Settings /wp-admin/edit.php?post_type=sp_easy_accordion&page=eap_settings1,3944.8764.6996.75

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
Please fix the following items
  • Zombie WordPress options were found after uninstall: 12 options
    • easy_accordion_free_db_version
    • sp_eap_settings
    • widget_theysaidso_widget
    • theysaidso_admin_options
    • easy_accordion_free_version
    • widget_recent-comments
    • sp_eafree_review_notice_dismiss
    • widget_recent-posts
    • easy_accordion_free_first_version
    • can_compress_scripts
    • ...

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)
The smoke test was a success, however most plugin functionality was not tested

SRP 50% from 2 tests

🔹 Tests weight: 20 | It is important to ensure that your PHP files perform no action when accessed directly, respecting the single-responsibility principle
Please fix the following
  • 9× GET requests to PHP files have triggered server-side errors or warnings:
    • > PHP Notice
      Undefined variable: ea_dynamic_css in wp-content/plugins/easy-accordion-free/public/dynamic-style.php on line 45
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_shortcode() in wp-content/plugins/easy-accordion-free/public/views/class-easy-accordion-free-shortcode.php:74
    • > PHP Fatal error
      Uncaught Error: Class 'Elementor\\Widget_Base' not found in wp-content/plugins/easy-accordion-free/admin/ElementAddons/Sp_Easy_Accordion_Shortcode_Widget.php:15
    • > PHP Notice
      Undefined variable: accordion_id in wp-content/plugins/easy-accordion-free/public/dynamic-style.php on line 45
    • > PHP Fatal error
      Uncaught Error: Call to undefined function update_option() in wp-content/plugins/easy-accordion-free/includes/updates/update-2.0.6.php:8
    • > PHP Fatal error
      Uncaught Error: Call to undefined function update_option() in wp-content/plugins/easy-accordion-free/includes/updates/update-2.1.14.php:8
    • > PHP Fatal error
      Uncaught Error: Call to undefined function update_option() in wp-content/plugins/easy-accordion-free/includes/updates/update-2.0.7.php:8
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_action() in wp-content/plugins/easy-accordion-free/admin/preview/class-easy-accordion-free-preview.php:32
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_action() in wp-content/plugins/easy-accordion-free/admin/class-easy-accordion-free-element-shortcode-addons.php:127

User-side errors Passed 1 test

🔹 Test weight: 20 | This is a shallow check for browser errors
Everything seems fine, but this is not an exhaustive test

Optimizations

Plugin configuration 93% 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 to be fixed:
  • Tags: Please reduce the number of tags, currently 36 tag instead of maximum 10
You can look at the official readme.txt

easy-accordion-free/plugin-main.php 92% from 13 tests

"Easy Accordion - Best Accordion FAQ Plugin for WordPress" version 2.2.5's primary PHP file adds more information about the plugin and serves as the entry point for WordPress
You should first fix the following items:
  • Main file name: Name the main plugin file the same as the plugin slug ("easy-accordion-free.php" instead of "plugin-main.php")

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | There should be no dangerous file extensions present in any WordPress plugin
Success! There were no dangerous files found in this plugin16,240 lines of code in 109 files:
LanguageFilesBlank linesComment linesLines of code
PHP671,4262,8835,575
CSS136423624,017
JavaScript91,0473153,899
SVG20022,749

PHP code Passed 2 tests

This is a short overview of cyclomatic complexity and code structure for this plugin
Great job! No cyclomatic complexity issues were detected in this plugin
Cyclomatic complexity
Average complexity per logical line of code0.57
Average class complexity20.28
▷ Minimum class complexity1.00
▷ Maximum class complexity129.00
Average method complexity5.71
▷ Minimum method complexity1.00
▷ Maximum method complexity66.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes47
▷ Abstract classes24.26%
▷ Concrete classes4595.74%
▷ Final classes00.00%
Methods193
▷ Static methods3216.58%
▷ Public methods18696.37%
▷ Protected methods21.04%
▷ Private methods52.59%
Functions22
▷ Named functions2195.45%
▷ Anonymous functions14.55%
Constants6
▷ Global constants6100.00%
▷ Class constants00.00%
▷ Public constants00.00%

Plugin size Passed 2 tests

Image compression Passed 2 tests

Often times overlooked, PNG files can occupy unnecessary space in your plugin
21 PNG files occupy 0.04MB with 0.01MB in potential savings
Potential savings
Compression of 5 random PNG files using pngquant
FileSize - originalSize - compressedSavings
admin/img/7-hand.png1.27KB0.60KB▼ 52.92%
admin/img/8-caret.png1.14KB0.24KB▼ 79.21%
admin/img/chosen-sprite.png0.63KB0.88KB0.00%
admin/img/checkerboard.png2.02KB2.54KB0.00%
admin/views/models/assets/images/checkerboard.png2.29KB2.54KB0.00%