84% quickdocs

Code Review | QuickDocs

WordPress plugin QuickDocs scored 84% from 54 tests.

About plugin

  • Plugin page: quickdocs
  • Plugin version: 1.0.0
  • PHP compatiblity: 7.4.0+
  • PHP version: 7.4.16
  • WordPress compatibility: 5.2-6.1
  • WordPress version: 6.3.1
  • First release: Jan 11, 2023
  • Latest release: Jan 11, 2023
  • Number of updates: 20
  • Update frequency: every 1.7 days
  • Top authors: wrdstudio (100%)

Code review

54 tests

User reviews

1 review

Install metrics

10+ active / 167 total downloads

Benchmarks

Plugin footprint 83% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | Verifying that this plugin installs correctly without errors
Install script ran successfully

Server metrics [RAM: ▲0.39MB] [CPU: ▲1.85ms] Passed 4 tests

Server-side resources used by QuickDocs
Normal server usage
PageMemory (MB)CPU Time (ms)
Home /3.87 ▲0.4142.41 ▲2.88
Dashboard /wp-admin3.70 ▲0.4047.70 ▲0.68
Posts /wp-admin/edit.php3.76 ▲0.4050.37 ▲4.84
Add New Post /wp-admin/post-new.php6.37 ▲0.4990.44 ▼1.02
Media Library /wp-admin/upload.php3.56 ▲0.3441.17 ▲9.08
Add Article /wp-admin/post-new.php?post_type=wrd_docs6.3785.44
Settings /wp-admin/edit.php?post_type=wrd_docs&page=quickdocs-settings3.5533.84
All Articles /wp-admin/edit.php?post_type=wrd_docs3.6134.87
Topic /wp-admin/edit-tags.php?taxonomy=topic&post_type=wrd_docs3.5636.56

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

Analyzing filesystem and database footprints of this plugin
This plugin was installed successfully
Filesystem: 47 new files
Database: no new tables, 6 new options
New WordPress options
db_upgraded
widget_recent-comments
can_compress_scripts
widget_recent-posts
theysaidso_admin_options
widget_theysaidso_widget

Browser metrics Passed 4 tests

QuickDocs: an overview of browser usage
Normal browser usage
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,855 ▲12013.35 ▼1.331.71 ▼0.3845.70 ▼5.37
Dashboard /wp-admin2,258 ▲704.86 ▼0.17102.23 ▼17.4938.14 ▼9.10
Posts /wp-admin/edit.php2,141 ▲522.03 ▲0.0139.66 ▲2.1334.19 ▼0.70
Add New Post /wp-admin/post-new.php1,557 ▲2423.40 ▲0.55660.67 ▲19.7253.16 ▲4.61
Media Library /wp-admin/upload.php1,441 ▲564.17 ▼0.11109.28 ▲9.4646.83 ▲3.77
Add Article /wp-admin/post-new.php?post_type=wrd_docs6,52120.57874.9335.34
Settings /wp-admin/edit.php?post_type=wrd_docs&page=quickdocs-settings1,0042.0424.3625.35
All Articles /wp-admin/edit.php?post_type=wrd_docs1,1152.0029.9425.48
Topic /wp-admin/edit-tags.php?taxonomy=topic&post_type=wrd_docs1,3382.1727.3527.93

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
  • Zombie WordPress options detected upon uninstall: 6 options
    • widget_recent-posts
    • theysaidso_admin_options
    • widget_recent-comments
    • can_compress_scripts
    • db_upgraded
    • widget_theysaidso_widget

Smoke tests 75% from 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | A shallow check that no server-side errors were triggered
Good news, no errors were detected

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
Almost there! Just fix the following items
  • 14× PHP files trigger errors when accessed directly with GET requests (only 10 are shown):
    • > PHP Fatal error
      Uncaught Error: Call to undefined function get_post_meta() in wp-content/plugins/quickdocs/metaboxes/article-state.php:11
    • > PHP Fatal error
      Uncaught Error: Call to undefined function quickdocs\\settings_fields() in wp-content/plugins/quickdocs/templates/partials/settings-home.php:16
    • > PHP Fatal error
      Uncaught Error: Call to undefined function the_permalink() in wp-content/plugins/quickdocs/templates/partials/content-article.php:14
    • > PHP Fatal error
      Uncaught Error: Call to undefined function quickdocs\\settings_fields() in wp-content/plugins/quickdocs/templates/partials/settings-design.php:14
    • > PHP Fatal error
      Uncaught Error: Call to undefined function wp_footer() in wp-content/plugins/quickdocs/templates/partials/footer.php:15
    • > PHP Warning
      Use of undefined constant WP_PLUGIN_URL - assumed 'WP_PLUGIN_URL' (this will throw an Error in a future version of PHP) in wp-content/plugins/quickdocs/quickdocs.php on line 108
    • > PHP Fatal error
      Uncaught Error: Call to undefined function quickdocs\\language_attributes() in wp-content/plugins/quickdocs/templates/partials/header.php:16
    • > PHP Warning
      Use of undefined constant WP_PLUGIN_DIR - assumed 'WP_PLUGIN_DIR' (this will throw an Error in a future version of PHP) in wp-content/plugins/quickdocs/quickdocs.php on line 108
    • > PHP Fatal error
      require_once(): Failed opening required 'WP_PLUGIN_DIR/quickdocs/src/class-metabox.php' (include_path='.:/usr/share/php') in wp-content/plugins/quickdocs/quickdocs.php on line 46
    • > PHP Fatal error
      Uncaught Error: Call to undefined function quickdocs\\language_attributes() in wp-content/plugins/quickdocs/templates/partials/header.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)
Everything seems fine, but this is not an exhaustive test

Optimizations

Plugin configuration 96% from 29 tests

readme.txt Passed 16 tests

The readme.txt file is important because it is parsed by WordPress.org for the public listing of your plugin
7 plugin tags: code, document, documentation, coding, guide...

quickdocs/quickdocs.php 92% from 13 tests

This is the main PHP file of "QuickDocs" version 1.0.0, providing information about the plugin in the header fields and serving as the principal entry point to the plugin's functions
Please make the necessary changes and fix the following:
  • Domain Path: The domain path folder does not exist ("/languages")

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
Everything looks great! No dangerous files found in this plugin5,483 lines of code in 44 files:
LanguageFilesBlank linesComment linesLines of code
PHP309851,6943,358
JavaScript5558985
CSS215817956
JSON20092
Markdown132054
SVG40038

PHP code Passed 2 tests

An short overview of logical lines of code, cyclomatic complexity, and other code metrics
Great job! No cyclomatic complexity issues were detected in this plugin
Cyclomatic complexity
Average complexity per logical line of code0.39
Average class complexity26.21
▷ Minimum class complexity1.00
▷ Maximum class complexity186.00
Average method complexity3.09
▷ Minimum method complexity1.00
▷ Maximum method complexity26.00
Code structure
Namespaces3
Interfaces0
Traits0
Classes14
▷ Abstract classes00.00%
▷ Concrete classes14100.00%
▷ Final classes00.00%
Methods172
▷ Static methods2715.70%
▷ Public methods10259.30%
▷ Protected methods4425.58%
▷ Private methods2615.12%
Functions31
▷ Named functions2787.10%
▷ Anonymous functions412.90%
Constants12
▷ Global constants00.00%
▷ Class constants12100.00%
▷ Public constants12100.00%

Plugin size Passed 2 tests

Image compression Passed 2 tests

All PNG images should be compressed to minimize bandwidth usage for end users
No PNG images were found in this plugin