84% adonide-faq-plugin

Code Review | FAQ plugin

WordPress plugin FAQ plugin scored84%from 54 tests.

About plugin

  • Plugin page: adonide-faq-plugin
  • Plugin version: 2.2.2
  • PHP version: 7.4.16
  • WordPress compatibility: 3.6.0-4.4
  • WordPress version: 6.3.1
  • First release: Jul 18, 2012
  • Latest release: Mar 31, 2016
  • Number of updates: 83
  • Update frequency: every 16.3 days
  • Top authors: djerba (100%)

Code review

54 tests

User reviews

1 review

Install metrics

10+ active /6,056 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
The plugin installed gracefully, with no errors

Server metrics [RAM: ▲0.07MB] [CPU: ▼2.87ms] Passed 4 tests

A check of server-side resources used by FAQ plugin
This plugin does not affect your website's performance
PageMemory (MB)CPU Time (ms)
Home /3.55 ▲0.0940.42 ▲0.85
Dashboard /wp-admin3.37 ▲0.0752.71 ▼1.61
Posts /wp-admin/edit.php3.42 ▲0.0658.20 ▲5.64
Add New Post /wp-admin/post-new.php5.97 ▲0.0986.59 ▼10.07
Media Library /wp-admin/upload.php3.29 ▲0.0637.09 ▼0.63
Help /wp-admin/edit.php?post_type=adonide_faq&page=adonide-faq-plugin/core/html-faq-page-postType.php3.2639.59
New Question /wp-admin/post-new.php?post_type=adonide_faq3.4456.20
Taxonomies /wp-admin/edit-tags.php?taxonomy=taxonomies&post_type=adonide_faq3.2939.52
All questions /wp-admin/edit.php?post_type=adonide_faq3.3437.17

Server storage [IO: ▲0.52MB] [DB: ▲0.07MB] Passed 3 tests

Analyzing filesystem and database footprints of this plugin
There were no storage issued detected upon installing this plugin
Filesystem: 27 new files
Database: no new tables, 7 new options
New WordPress options
can_compress_scripts
widget_recent-comments
db_upgraded
theysaidso_admin_options
faqPage_plugin_signature
widget_theysaidso_widget
widget_recent-posts

Browser metrics Passed 4 tests

This is an overview of browser requirements for FAQ plugin
There were no issues detected in relation to browser resource usage
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,932 ▲17113.84 ▼0.8410.77 ▲8.2641.46 ▼2.42
Dashboard /wp-admin2,221 ▲415.60 ▼0.0786.50 ▼13.9873.27 ▲26.36
Posts /wp-admin/edit.php2,141 ▲382.00 ▼0.0338.10 ▲3.2535.25 ▲0.71
Add New Post /wp-admin/post-new.php1,402 ▼12416.69 ▼0.84581.43 ▼95.1851.08 ▼0.07
Media Library /wp-admin/upload.php1,432 ▲324.24 ▲0.02105.82 ▲8.3384.29 ▲35.26
Help /wp-admin/edit.php?post_type=adonide_faq&page=adonide-faq-plugin/core/html-faq-page-postType.php1,0442.6635.3031.71
New Question /wp-admin/post-new.php?post_type=adonide_faq2,7827.75177.99158.10
Taxonomies /wp-admin/edit-tags.php?taxonomy=taxonomies&post_type=adonide_faq1,3152.1627.1333.24
All questions /wp-admin/edit.php?post_type=adonide_faq1,1531.9730.9532.92

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

🔸 Tests weight: 35 | It is important to correctly uninstall your plugin, without leaving any traces
It is recommended to fix the following
  • This plugin does not fully uninstall, leaving 7 options in the database
    • widget_theysaidso_widget
    • theysaidso_admin_options
    • widget_recent-comments
    • db_upgraded
    • faqPage_plugin_signature
    • widget_recent-posts
    • 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)
Even though everything seems fine, this is not an exhaustive test

SRP 50% 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
The following issues need your attention
  • 2× PHP files perform the task of outputting text when accessed with GET requests:
    • > /wp-content/plugins/adonide-faq-plugin/core/updateList.php
    • > /wp-content/plugins/adonide-faq-plugin/index.php

User-side errors Passed 1 test

🔹 Test weight: 20 | This is just a short smoke test looking for browser issues
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 undoubtedly the most important file in your plugin, preparing it for public listing on WordPress.org
Please fix the following attributes:
  • Screenshots: Screenshot #1 (FAQ plugin configuration panel) image required
The official readme.txt might help

adonide-faq-plugin/index.php 92% from 13 tests

The principal PHP file in "FAQ plugin" v. 2.2.2 is loaded by WordPress automatically on each request
You should first fix the following items:
  • Main file name: Name the main plugin file the same as the plugin slug ("adonide-faq-plugin.php" instead of "index.php")

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 plugin7,338 lines of code in 13 files:
LanguageFilesBlank linesComment linesLines of code
JavaScript51,4671,0336,677
PHP425109357
PO File291122153
CSS215151

PHP code Passed 2 tests

A short review of 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.15
Average class complexity7.50
▷ Minimum class complexity3.00
▷ Maximum class complexity12.00
Average method complexity1.56
▷ Minimum method complexity1.00
▷ Maximum method complexity5.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes2
▷ Abstract classes00.00%
▷ Concrete classes2100.00%
▷ Final classes00.00%
Methods19
▷ Static methods15.26%
▷ Public methods19100.00%
▷ Protected methods00.00%
▷ Private methods00.00%
Functions1
▷ Named functions1100.00%
▷ Anonymous functions00.00%
Constants0
▷ Global constants00.00%
▷ Class constants00.00%
▷ Public constants00.00%

Plugin size Passed 2 tests

Image compression Passed 2 tests

It is recommended to compress PNG files in your plugin to minimize bandwidth usage
10 PNG files occupy 0.09MB with 0.03MB in potential savings
Potential savings
Compression of 5 random PNG files using pngquant
FileSize - originalSize - compressedSavings
core/images/move.png0.56KB0.33KB▼ 40.42%
core/images/facebook-ogg-meta-tags.png5.17KB1.93KB▼ 62.60%
core/images/icon-24.png0.97KB0.94KB▼ 2.22%
core/images/plug-and-play.png4.91KB1.75KB▼ 64.38%
core/js/question-btn.png0.58KB0.67KB0.00%