89% frequently-asked-questions

Code Review | WordPress FAQ -- Frequently Asked Questions Plugin

WordPress plugin WordPress FAQ -- Frequently Asked Questions Plugin scored 89% from 54 tests.

About plugin

  • Plugin page: frequently-asked-...
  • Plugin version: 3.7.5
  • PHP version: 7.4.16
  • WordPress compatibility: 4.0-6.0
  • WordPress version: 6.3.1
  • First release: Mar 23, 2019
  • Latest release: Jun 19, 2022
  • Number of updates: 21
  • Update frequency: every 56.4 days
  • Top authors: zhuyi (100%)

Code review

54 tests

User reviews

1 review

Install metrics

30+ active / 1,061 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 successfully, without throwing any errors or notices

Server metrics [RAM: ▲0.14MB] [CPU: ▲7.08ms] Passed 4 tests

This is a short check of server-side resources used by WordPress FAQ -- Frequently Asked Questions Plugin
This plugin has minimal impact on server resources
PageMemory (MB)CPU Time (ms)
Home /3.61 ▲0.1547.72 ▲6.63
Dashboard /wp-admin3.44 ▲0.1454.29 ▲8.93
Posts /wp-admin/edit.php3.54 ▲0.1859.92 ▲14.83
Add New Post /wp-admin/post-new.php6.02 ▲0.1494.64 ▲1.71
Media Library /wp-admin/upload.php3.36 ▲0.1444.50 ▲11.05
Add New /wp-admin/post-new.php?post_type=faq3.4960.43
All FAQ /wp-admin/edit.php?post_type=faq3.3942.64
Categories /wp-admin/edit-tags.php?taxonomy=faq_categories&post_type=faq3.3642.22
Global Settings /wp-admin/edit.php?post_type=faq&page=faqglobalsettings3.3338.91

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

Input-output and database impact of this plugin
No storage issues were detected
Filesystem: 89 new files
Database: no new tables, 6 new options
New WordPress options
widget_recent-comments
db_upgraded
theysaidso_admin_options
widget_recent-posts
can_compress_scripts
widget_theysaidso_widget

Browser metrics Passed 4 tests

Checking browser requirements for WordPress FAQ -- Frequently Asked Questions Plugin
Normal browser usage
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,961 ▲22614.59 ▼0.0116.90 ▲15.0836.04 ▼12.60
Dashboard /wp-admin2,241 ▲535.79 ▲0.8795.75 ▼7.7137.06 ▼9.71
Posts /wp-admin/edit.php2,124 ▲352.01 ▲0.0041.37 ▲4.7435.59 ▲0.24
Add New Post /wp-admin/post-new.php1,562 ▲2923.47 ▲0.27664.47 ▲6.6460.48 ▲4.47
Media Library /wp-admin/upload.php1,420 ▲354.17 ▼0.0997.70 ▼23.5344.03 ▼6.06
Add New /wp-admin/post-new.php?post_type=faq2,5607.76192.4869.96
All FAQ /wp-admin/edit.php?post_type=faq1,1051.9730.8629.70
Categories /wp-admin/edit-tags.php?taxonomy=faq_categories&post_type=faq1,2942.1427.4127.01
Global Settings /wp-admin/edit.php?post_type=faq&page=faqglobalsettings1,0502.0222.1826.29

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

🔸 Tests weight: 35 | Checking the uninstaller removed all traces of the plugin
Please fix the following items
  • The uninstall procedure has failed, leaving 6 options in the database
    • widget_recent-posts
    • widget_recent-comments
    • theysaidso_admin_options
    • can_compress_scripts
    • widget_theysaidso_widget
    • db_upgraded

Smoke tests Passed 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | This is a shallow check for server-side errors
Even though no errors were found, this is by no means an exhaustive test

SRP Passed 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
Looking good! No server-side errors or output on direct access of PHP files

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 90% from 29 tests

readme.txt 94% from 16 tests

Don't ignore readme.txt as it is the file that instructs WordPress.org on how to present your plugin to the world
Please fix the following attributes: Please take inspiration from this readme.txt

frequently-asked-questions/faq.php 85% from 13 tests

The primary PHP file in "WordPress FAQ -- Frequently Asked Questions Plugin" version 3.7.5 is used by WordPress to initiate all plugin functionality
The following require your attention:
  • Text Domain: The text domain must be the same as the plugin slug, although optional since WordPress version 4.6
  • Main file name: The principal plugin file should be the same as the plugin slug ("frequently-asked-questions.php" instead of "faq.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
There were no executable files found in this plugin29,445 lines of code in 24 files:
LanguageFilesBlank linesComment linesLines of code
JavaScript45,1433,93620,668
CSS142723537,745
PHP411284511
HTML19616447
JSON10074

PHP code Passed 2 tests

This is a very shot review of cyclomatic complexity and code structure
There are no cyclomatic complexity problems detected for this plugin
Cyclomatic complexity
Average complexity per logical line of code0.33
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%
Functions12
▷ Named functions12100.00%
▷ Anonymous functions00.00%
Constants1
▷ Global constants1100.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
49 PNG files occupy 0.18MB with 0.07MB in potential savings
Potential savings
Compression of 5 random PNG files using pngquant
FileSize - originalSize - compressedSavings
asset/faq-black-blue-theme/images/ui-icons_ffffff_256x240.png6.15KB4.17KB▼ 32.13%
asset/faq-black-blue-theme/images/ui-icons_9ccdfc_256x240.png4.44KB4.17KB▼ 6.02%
asset/css-new/themes/greenblue/images/ui-bg_glass_75_79c9ec_1x400.png0.34KB0.16KB▼ 52.87%
asset/faq-black-blue-theme/images/ui-bg_dots-small_20_333333_2x2.png0.20KB0.08KB▼ 57.77%
asset/css-new/themes/greenblue/images/ui-bg_gloss-wave_75_2191c0_500x100.png5.84KB2.74KB▼ 53.09%