84% cb-faq-responsive-accordion

Code Review | CB FAQ Responsive Accordion

WordPress plugin CB FAQ Responsive Accordion scored 84% from 54 tests.

About plugin

  • Plugin page: cb-faq-responsive...
  • Plugin version: 1.1
  • PHP version: 7.4.16
  • WordPress compatibility: 4.3-5.0
  • WordPress version: 6.3.1
  • First release: Sep 1, 2015
  • Latest release: Dec 12, 2018
  • Number of updates: 12
  • Update frequency: every 99.8 days
  • Top authors: hmbashar (100%)

Code review

54 tests

User reviews

1 review

Install metrics

10+ active / 1,517 total downloads

Benchmarks

Plugin footprint 83% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | It is important to correctly install your plugin, without throwing errors or notices
This plugin's installer ran successfully

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

A check of server-side resources used by CB FAQ Responsive Accordion
This plugin does not affect your website's performance
PageMemory (MB)CPU Time (ms)
Home /3.49 ▲0.0338.41 ▼2.32
Dashboard /wp-admin3.33 ▲0.0349.17 ▲0.70
Posts /wp-admin/edit.php3.38 ▲0.0246.29 ▲2.44
Add New Post /wp-admin/post-new.php5.91 ▲0.0282.96 ▼11.23
Media Library /wp-admin/upload.php3.25 ▲0.0235.31 ▲1.66
Accordions /wp-admin/edit.php?post_type=accordions3.2935.36
Add New Accordion /wp-admin/post-new.php?post_type=accordions3.3646.02

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

Analyzing filesystem and database footprints of this plugin
This plugin installed successfully
Filesystem: 12 new files
Database: no new tables, 6 new options
New WordPress options
widget_recent-comments
theysaidso_admin_options
widget_theysaidso_widget
can_compress_scripts
widget_recent-posts
db_upgraded

Browser metrics Passed 4 tests

A check of browser resources used by CB FAQ Responsive Accordion
There were no issues detected in relation to browser resource usage
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,913 ▲17813.94 ▼0.455.00 ▲3.3337.52 ▼9.02
Dashboard /wp-admin2,230 ▲474.87 ▼1.03110.18 ▼9.6739.51 ▼1.04
Posts /wp-admin/edit.php2,119 ▲302.03 ▼0.0139.92 ▲4.1835.65 ▲3.22
Add New Post /wp-admin/post-new.php1,556 ▲2323.28 ▲0.31660.22 ▲57.3563.45 ▲20.72
Media Library /wp-admin/upload.php1,415 ▲304.22 ▲0.0595.03 ▼2.2941.90 ▼4.47
Accordions /wp-admin/edit.php?post_type=accordions1,0892.0234.8530.08
Add New Accordion /wp-admin/post-new.php?post_type=accordions2,1637.67167.7759.39

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

🔸 Tests weight: 35 | It is important to correctly uninstall your plugin, without leaving any traces
You still need to fix the following
  • Zombie WordPress options were found after uninstall: 6 options
    • can_compress_scripts
    • widget_recent-comments
    • theysaidso_admin_options
    • widget_theysaidso_widget
    • db_upgraded
    • widget_recent-posts

Smoke tests 75% from 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | This is a shallow check for server-side errors
Good news, no errors were detected

SRP 50% from 2 tests

🔹 Tests weight: 20 | SRP (Single-Responsibility Principle) - PHP files must act as libraries and never output text or perform any action when accessed directly in a browser
Please fix the following items
  • 1× PHP files trigger server errors when accessed directly:
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_action() in wp-content/plugins/cb-faq-responsive-accordion/index.php:37

User-side errors Passed 1 test

🔹 Test weight: 20 | This is a smoke test targeting browser errors/issues
Everything seems fine, but this is not an exhaustive test

Optimizations

Plugin configuration 96% from 29 tests

readme.txt Passed 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
6 plugin tags: wordpress responsive accordion with faq, wordpress faq, cb responsive accordion, wordpress faq plugin, accordion...

cb-faq-responsive-accordion/index.php 92% from 13 tests

The main PHP script in "CB FAQ Responsive Accordion" version 1.1 is automatically included on every request by WordPress
The following require your attention:
  • Main file name: Even though not officially enforced, the main plugin file should be the same as the plugin slug ("cb-faq-responsive-accordion.php" instead of "index.php")

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | A short check of programming languages and file extensions; no executable files are allowed
Everything looks great! No dangerous files found in this plugin435 lines of code in 4 files:
LanguageFilesBlank linesComment linesLines of code
SVG100188
CSS1153176
PHP127963
JavaScript1808

PHP code Passed 2 tests

This is a short overview of cyclomatic complexity and code structure for this plugin
No complexity issues detected
Cyclomatic complexity
Average complexity per logical line of code0.10
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%
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
1 PNG file occupies 0.00MB with 0.00MB in potential savings
Potential savings
Compression of 1 random PNG file using pngquant
FileSize - originalSize - compressedSavings
images/right_arrow.png2.91KB0.38KB▼ 87.03%