78% wp-dlm-faq

Code Review | WP DLM FAQ

WordPress plugin WP DLM FAQ scored78%from 54 tests.

About plugin

  • Plugin page: wp-dlm-faq
  • Plugin version: 1.5.1
  • PHP version: 7.4.16
  • WordPress compatibility: 5.0-5.5
  • WordPress version: 6.3.1
  • First release: Aug 17, 2020
  • Latest release: Apr 30, 2021
  • Number of updates: 24
  • Update frequency: every 13.7 days
  • Top authors: dlmconversion (100%)

Code review

54 tests

User reviews

1 review

Install metrics

100+ active /991 total downloads

Benchmarks

Plugin footprint 83% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | The install procedure must perform silently
Installer ran successfully

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

Server-side resources used by WP DLM FAQ
This plugin has minimal impact on server resources
PageMemory (MB)CPU Time (ms)
Home /3.53 ▲0.0738.80 ▼1.23
Dashboard /wp-admin3.38 ▲0.0845.51 ▼4.76
Posts /wp-admin/edit.php3.43 ▲0.0746.92 ▲3.29
Add New Post /wp-admin/post-new.php5.96 ▲0.0785.35 ▼1.23
Media Library /wp-admin/upload.php3.30 ▲0.0733.90 ▼0.95
DLM FAQ /wp-admin/options-general.php?page=my-setting-admin3.2428.63

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

Filesystem and database footprint
The plugin installed successfully
Filesystem: 5 new files
Database: no new tables, 7 new options
New WordPress options
widget_recent-comments
theysaidso_admin_options
can_compress_scripts
db_upgraded
widget_recent-posts
recovery_mode_email_last_sent
widget_theysaidso_widget

Browser metrics Passed 4 tests

A check of browser resources used by WP DLM FAQ
Minimal impact on browser resources
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,923 ▲16613.75 ▼0.997.58 ▲5.4340.01 ▼4.92
Dashboard /wp-admin2,207 ▲194.89 ▼0.01101.22 ▼16.4044.52 ▼1.37
Posts /wp-admin/edit.php2,096 ▲72.03 ▼0.1236.79 ▲0.6930.46 ▼7.28
Add New Post /wp-admin/post-new.php1,523 ▼1023.23 ▲0.20657.01 ▲10.1954.20 ▼1.44
Media Library /wp-admin/upload.php1,395 ▲74.18 ▼0.0398.48 ▼0.9644.02 ▼3.02
DLM FAQ /wp-admin/options-general.php?page=my-setting-admin7361.147.1323.77

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

🔸 Tests weight: 35 | All plugins must uninstall correctly, removing their source code and extra database tables they might have created
It is recommended to fix the following
  • This plugin did not uninstall successfully, leaving 7 options in the database
    • can_compress_scripts
    • widget_recent-comments
    • theysaidso_admin_options
    • db_upgraded
    • widget_recent-posts
    • recovery_mode_email_last_sent
    • widget_theysaidso_widget

Smoke tests 50% from 4 tests

Server-side errors 0% from 1 test

🔹 Test weight: 20 | Just a short smoke test targeting errors on the server (in the Apache logs)
Please fix the following server-side errors
    • > GET request to /wp-admin/options-general.php?page=my-setting-admin
    • > Notice in wp-content/plugins/wp-dlm-faq/wp-dlm-faq.php+239
    Trying to access array offset on value of type bool
    • > GET request to /wp-admin/options-general.php?page=my-setting-admin
    • > Notice in wp-content/plugins/wp-dlm-faq/wp-dlm-faq.php+152
    Undefined variable: my_options
    • > GET request to /wp-admin/options-general.php?page=my-setting-admin
    • > Notice in wp-content/plugins/wp-dlm-faq/wp-dlm-faq.php+152
    Trying to access array offset on value of type null
    • > GET request to /wp-admin/options-general.php?page=my-setting-admin
    • > Error in wp-content/plugins/wp-dlm-faq/wp-dlm-faq.php+157
    Uncaught Error: Call to undefined function get_field() in wp-content/plugins/wp-dlm-faq/wp-dlm-faq.php:157
    Stack trace:
    #0 wp-admin/includes/template.php(1824): MySettingsPage->faq_categories_callback()
    #1 wp-admin/includes/template.php(1778): do_settings_fields()
    #2 wp-content/plugins/wp-dlm-faq/wp-dlm-faq.php(63): do_settings_sections()
    #3 wp-includes/class-wp-hook.php(310): MySettingsPage->create_admin_page()
    #4 wp-includes/class-wp-hook.php(334): WP_Hook->apply_filters()
    #5 wp-includes/plugin.php(517): WP_Hook->do_action()
    #6 wp-admin/admin.php(259): do_action()
    #7 wp-admin/options-general.php(10): require_once('/var/www/wordpr...')
    #8 {main}
    thrown

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
The following issues need your attention
  • 1× PHP files trigger server-side errors or warnings when accessed directly:
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_action() in wp-content/plugins/wp-dlm-faq/wp-dlm-faq.php:16

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)
No browser errors were detected

Optimizations

Plugin configuration 97% 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
Attributes that need to be fixed: You can look at the official readme.txt

wp-dlm-faq/wp-dlm-faq.php Passed 13 tests

The main PHP script in "WP DLM FAQ" version 1.5.1 is automatically included on every request by WordPress
24 characters long description:
The plugin used for faq.

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | There should be no dangerous file extensions present in any WordPress plugin
Success! There were no dangerous files found in this plugin456 lines of code in 3 files:
LanguageFilesBlank linesComment linesLines of code
PHP19356386
CSS102047
JavaScript10123

PHP code Passed 2 tests

Analyzing logical lines of code, cyclomatic complexity, and other code metrics
There were no cyclomatic complexity issued detected
Cyclomatic complexity
Average complexity per logical line of code0.43
Average class complexity10.00
▷ Minimum class complexity10.00
▷ Maximum class complexity10.00
Average method complexity1.90
▷ Minimum method complexity1.00
▷ Maximum method complexity4.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes1
▷ Abstract classes00.00%
▷ Concrete classes1100.00%
▷ Final classes00.00%
Methods10
▷ Static methods00.00%
▷ Public methods10100.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
1 compressed PNG file occupies 0.00MB
Potential savings
Compression of 1 random PNG file using pngquant
FileSize - originalSize - compressedSavings
assets/arrw_rgt.png0.20KB0.19KB▼ 6.70%