82% accordions-and-tabs-by-vander-web

Code Review | Accordions and Tabs by Vander Web

WordPress plugin Accordions and Tabs by Vander Web scored 82% from 54 tests.

About plugin

  • Plugin page: accordions-and-ta...
  • Plugin version: 1.0.1
  • PHP compatiblity: 5.6.20+
  • PHP version: 7.4.16
  • WordPress compatibility: 5.3-5.6.1
  • WordPress version: 5.9.2
  • First release: Mar 4, 2021
  • Latest release: Mar 4, 2021
  • Number of updates: 2
  • Update frequency: every 7.0 days
  • Top authors: ulrikvander (100%)

Code review

54 tests

User reviews

1 review

Install metrics

10+ active / 200 total downloads


Plugin footprint Passed 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | All plugins must install correctly, without throwing any errors, warnings, or notices
The plugin installed successfully, without throwing any errors or notices

Server metrics [RAM: ▲0.11MB] [CPU: ▼292.29ms] Passed 4 tests

This is a short check of server-side resources used by Accordions and Tabs by Vander Web
Server-side resource usage in normal parameters
PageMemory (MB)CPU Time (ms)
Home /3.60 ▲0.0954.62 ▲5.33
Dashboard /wp-admin3.56 ▲0.1632.88 ▲0.77
Posts /wp-admin/edit.php3.79 ▲0.1536.88 ▲0.63
Add New Post /wp-admin/post-new.php7.04 ▲0.0795.50 ▼1,164.77
Media Library /wp-admin/upload.php3.45 ▲0.1527.00 ▼5.78
Add new /wp-admin/post-new.php?post_type=vanderweb_accordions3.7843.78
Sections /wp-admin/edit-tags.php?taxonomy=vanderweb_acc_section&post_type=vanderweb_accordions3.4524.35
Shortcodes /wp-admin/edit.php?post_type=vanderweb_accordions&page=vanderweb-accordions-shortcodes3.4224.45
Accordion items /wp-admin/edit.php?post_type=vanderweb_accordions3.5524.34

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

A short overview of filesystem and database impact
This plugin installed successfully
Filesystem: 32 new files
Database: no new tables, no new options

Browser metrics Passed 4 tests

Accordions and Tabs by Vander Web: an overview of browser usage
This plugin renders optimally with no browser resource issues detected
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /3,926 ▲17816.19 ▲0.518.78 ▲2.992.33 ▼0.15
Dashboard /wp-admin2,942 ▲886.16 ▼0.10119.29 ▼17.01158.41 ▼3.36
Posts /wp-admin/edit.php2,742 ▲543.24 ▲0.0160.49 ▼3.70141.13 ▼1.12
Add New Post /wp-admin/post-new.php1,814 ▲5422.26 ▼0.59415.41 ▼0.03162.38 ▲8.01
Media Library /wp-admin/upload.php1,751 ▲535.54 ▲0.01137.71 ▼6.12189.26 ▼1.02
Add new /wp-admin/post-new.php?post_type=vanderweb_accordions2,9489.94194.47196.84
Sections /wp-admin/edit-tags.php?taxonomy=vanderweb_acc_section&post_type=vanderweb_accordions1,6722.7755.03108.98
Shortcodes /wp-admin/edit.php?post_type=vanderweb_accordions&page=vanderweb-accordions-shortcodes1,2332.4454.99126.92
Accordion items /wp-admin/edit.php?post_type=vanderweb_accordions1,4273.1661.30111.66

Uninstaller [IO: ▲0.00MB] [DB: ▲0.00MB] Passed 4 tests

🔸 Tests weight: 35 | Verifying that this plugin uninstalls completely without leaving any traces
Uninstaller ran successfully

Smoke tests 25% from 4 tests

Server-side errors 0% from 1 test

🔹 Test weight: 20 | A smoke test targeting server-side errors
Please fix the following server-side errors
  • 2 occurences, only the last one shown
    • > GET request to /wp-admin/edit.php?post_type=vanderweb_accordions&page=vanderweb-accordions-shortcodes
    • > Notice in wp-content/plugins/accordions-and-tabs-by-vander-web/admin/class-vanderweb-bs4-accordion-admin.php+208
    Trying to access array offset on value of type bool

SRP 0% from 2 tests

🔹 Tests weight: 20 | The single-responsibility principle: PHP files have to remain inert when accessed directly, throwing no errors and performing no actions
The following issues need your attention
  • 1× PHP files output non-empty strings when accessed directly via GET requests:
    • > /wp-content/plugins/accordions-and-tabs-by-vander-web/public/partials/vanderweb-bs4-accordion-public-display.php
  • 1× GET requests to PHP files trigger server-side errors or Error 500 responses:
    • > PHP Fatal error
      Uncaught Error: Call to undefined function get_terms() in wp-content/plugins/accordions-and-tabs-by-vander-web/admin/partials/vanderweb-bs4-accordion-admin-display.php:17

User-side errors Passed 1 test

🔹 Test weight: 20 | This is a shallow check for browser errors
No browser errors were detected


Plugin configuration 90% from 29 tests

readme.txt 94% from 16 tests

The readme.txt file is important because it is parsed by WordPress.org for the public listing of your plugin
Please fix the following attributes:
  • Screenshots: Screenshot #1 (No screenshots available.) image not found
You can look at the official readme.txt

accordions-and-tabs-by-vander-web/vanderweb-bs4-accordion.php 85% from 13 tests

The main file in "Accordions and Tabs by Vander Web" v. 1.0.1 serves as a complement to information provided in readme.txt and as the entry point to the plugin
You should first fix the following items:
  • Text Domain: The text domain must be the same as the plugin slug, although optional since WordPress version 4.6
  • Main file name: Name the main plugin file the same as the plugin slug ("accordions-and-tabs-by-vander-web.php" instead of "vanderweb-bs4-accordion.php")

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | A short glimpse at programming languages used with this plugin and a check that no dangerous files are present
Success! There were no dangerous files found in this plugin1,951 lines of code in 21 files:
LanguageFilesBlank linesComment linesLines of code
PO File14355110

PHP code Passed 2 tests

Analyzing cyclomatic complexity and code structure
Although this was not an exhaustive test, there were no cyclomatic complexity issues detected
Cyclomatic complexity
Average complexity per logical line of code0.13
Average class complexity4.00
▷ Minimum class complexity1.00
▷ Maximum class complexity13.00
Average method complexity1.69
▷ Minimum method complexity1.00
▷ Maximum method complexity7.00
Code structure
▷ Abstract classes00.00%
▷ Concrete classes8100.00%
▷ Final classes00.00%
▷ Static methods25.71%
▷ Public methods3085.71%
▷ Protected methods00.00%
▷ Private methods514.29%
▷ Named functions3100.00%
▷ Anonymous functions00.00%
▷ Global constants1100.00%
▷ Class constants00.00%
▷ Public constants00.00%

Plugin size Passed 2 tests

Image compression Passed 2 tests

Using a strong compression for your PNG files is a great way to speed-up your plugin
No PNG files were detected