84% kings-faq

Code Review | Kings FAQ

WordPress plugin Kings FAQ scored84%from 54 tests.

About plugin

  • Plugin page: kings-faq
  • Plugin version: 1.1
  • PHP version: 7.4.16
  • WordPress compatibility: 3.0.1-4.1
  • WordPress version: 6.3.1
  • First release: Mar 27, 2015
  • Latest release: Jul 13, 2015
  • Number of updates: 4
  • Update frequency: every 27.0 days
  • Top authors: KingsRRF (100%)

Code review

54 tests

User reviews

1 review

Install metrics

10+ active /700 total downloads

Benchmarks

Plugin footprint 83% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | Checking the installer triggered no errors
The plugin installed successfully, without throwing any errors or notices

Server metrics [RAM: ▲0.04MB] [CPU: ▼7.13ms] Passed 4 tests

An overview of server-side resources used by Kings FAQ
This plugin has minimal impact on server resources
PageMemory (MB)CPU Time (ms)
Home /3.51 ▲0.0441.81 ▼6.39
Dashboard /wp-admin3.34 ▲0.0458.23 ▲4.49
Posts /wp-admin/edit.php3.39 ▲0.0445.42 ▼6.54
Add New Post /wp-admin/post-new.php5.92 ▲0.0489.33 ▼13.66
Media Library /wp-admin/upload.php3.27 ▲0.0439.77 ▼1.92
FAQ Category /wp-admin/edit-tags.php?taxonomy=kings_faq_cat&post_type=kings-faq-items3.2634.60
Add New /wp-admin/post-new.php?post_type=kings-faq-items3.3857.92
FAQ Items /wp-admin/edit.php?post_type=kings-faq-items3.3138.24

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

Input-output and database impact of this plugin
This plugin installed successfully
Filesystem: 4 new files
Database: no new tables, 6 new options
New WordPress options
theysaidso_admin_options
db_upgraded
can_compress_scripts
widget_recent-posts
widget_theysaidso_widget
widget_recent-comments

Browser metrics Passed 4 tests

Checking browser requirements for Kings FAQ
Normal browser usage
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,914 ▲15313.80 ▼0.807.85 ▲5.9537.14 ▼10.81
Dashboard /wp-admin2,230 ▲505.65 ▼0.0086.48 ▼15.8138.82 ▼11.50
Posts /wp-admin/edit.php2,135 ▲352.00 ▲0.0436.40 ▼1.3733.71 ▼1.21
Add New Post /wp-admin/post-new.php1,556 ▲2822.83 ▼0.23667.94 ▼17.0551.38 ▼7.69
Media Library /wp-admin/upload.php1,429 ▲324.24 ▲0.0299.21 ▼3.2245.87 ▲2.34
FAQ Category /wp-admin/edit-tags.php?taxonomy=kings_faq_cat&post_type=kings-faq-items1,3062.1327.4829.98
Add New /wp-admin/post-new.php?post_type=kings-faq-items2,2847.58166.4763.13
FAQ Items /wp-admin/edit.php?post_type=kings-faq-items1,1131.9130.6531.17

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
  • This plugin does not fully uninstall, leaving 6 options in the database
    • can_compress_scripts
    • widget_theysaidso_widget
    • theysaidso_admin_options
    • widget_recent-comments
    • 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
Even though everything seems fine, this is not an exhaustive test

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× GET requests to PHP files trigger server-side errors or Error 500 responses:
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_action() in wp-content/plugins/kings-faq/plugin-hook.php:19

User-side errors Passed 1 test

🔹 Test weight: 20 | Just a short smoke test targeting errors on the browser (console and network errors and warnings)
There were no browser issues found

Optimizations

Plugin configuration 96% from 29 tests

readme.txt Passed 16 tests

Perhaps the most important file in your plugin readme.txt gets parsed in order to generate the public listing of your plugin
3 plugin tags: faq, testimonial, jquery faq

kings-faq/plugin-hook.php 92% from 13 tests

The main file in "Kings FAQ" v. 1.1 serves as a complement to information provided in readme.txt and as the entry point to the plugin
Please take the time to fix the following:
  • Main file name: Please rename the main PHP file in this plugin to the plugin slug ("kings-faq.php" instead of "plugin-hook.php")

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | Executable files are not allowed as they can serve as attack vectors
No dangerous file extensions were detected81 lines of code in 3 files:
LanguageFilesBlank linesComment linesLines of code
PHP1332367
CSS1407
JavaScript1207

PHP code Passed 2 tests

Analyzing cyclomatic complexity and code structure
Everything seems fine, there were no complexity issues found
Cyclomatic complexity
Average complexity per logical line of code0.05
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%
Functions5
▷ Named functions5100.00%
▷ Anonymous functions00.00%
Constants0
▷ Global constants00.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 images were found in this plugin