83% doc8

Code Review | DoC8

WordPress plugin DoC8 scored83%from 54 tests.

About plugin

  • Plugin page: doc8
  • Plugin version: 1.0.0
  • PHP version: 7.4.16
  • WordPress version: 6.3.1
  • First release: Jul 31, 2018
  • Latest release: Jul 31, 2018
  • Number of updates: 2
  • Update frequency: N/A
  • Top authors: gcourse (100%)

Code review

54 tests

User reviews

1 review

Install metrics

10+ active /687 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.05MB] [CPU: ▼2.38ms] Passed 4 tests

A check of server-side resources used by DoC8
Server-side resource usage in normal parameters
PageMemory (MB)CPU Time (ms)
Home /3.51 ▲0.0544.85 ▲2.40
Dashboard /wp-admin3.36 ▲0.0663.08 ▲13.44
Posts /wp-admin/edit.php3.41 ▲0.0650.15 ▲1.09
Add New Post /wp-admin/post-new.php5.96 ▲0.0787.27 ▼6.03
Media Library /wp-admin/upload.php3.28 ▲0.0533.71 ▼6.99
Settings /wp-admin/edit.php?post_type=docu&page=settings3.2531.14
Documents /wp-admin/edit.php?post_type=docu3.3340.46
Add New /wp-admin/post-new.php?post_type=docu3.4350.75

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

How much does this plugin use your filesystem and database?
This plugin was installed successfully
Filesystem: 380 new files
Database: no new tables, 6 new options
New WordPress options
widget_recent-comments
can_compress_scripts
theysaidso_admin_options
db_upgraded
widget_theysaidso_widget
widget_recent-posts

Browser metrics Passed 4 tests

DoC8: an overview of browser usage
There were no issues detected in relation to browser resource usage
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,823 ▲6214.23 ▼0.142.02 ▲0.3643.35 ▲3.28
Dashboard /wp-admin2,226 ▲485.58 ▼0.05103.37 ▼4.8549.88 ▲6.89
Posts /wp-admin/edit.php2,131 ▲311.97 ▲0.0143.49 ▲8.7335.47 ▼1.32
Add New Post /wp-admin/post-new.php1,560 ▲3418.28 ▼4.97652.08 ▼37.9367.26 ▲16.39
Media Library /wp-admin/upload.php1,431 ▲344.21 ▲0.05102.60 ▼11.8846.04 ▼3.81
Settings /wp-admin/edit.php?post_type=docu&page=settings9552.0224.3130.54
Documents /wp-admin/edit.php?post_type=docu1,1041.9729.7530.38
Add New /wp-admin/post-new.php?post_type=docu2,3787.59164.9474.75

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

🔸 Tests weight: 35 | Verifying that this plugin uninstalls completely without leaving any traces
The following items require your attention
  • Zombie WordPress options detected upon uninstall: 6 options
    • widget_theysaidso_widget
    • widget_recent-posts
    • db_upgraded
    • theysaidso_admin_options
    • can_compress_scripts
    • widget_recent-comments

Smoke tests 75% from 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | This is a short smoke test looking for server-side errors
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
Almost there! Just fix the following items
  • 3× GET requests to PHP files trigger server-side errors or Error 500 responses:
    • > PHP Fatal error
      Uncaught Error: Call to undefined function register_setting() in wp-content/plugins/doc8/inc/class-doc8-settings.php:12
    • > PHP Fatal error
      Uncaught Error: Call to undefined function get_header() in wp-content/plugins/doc8/templates/archive-standard.php:5
    • > PHP Fatal error
      Uncaught Error: Call to undefined function the_ID() in wp-content/plugins/doc8/templates/content-single-document.php:9

User-side errors Passed 1 test

🔹 Test weight: 20 | This is a shallow check for browser errors
There were no browser issues found

Optimizations

Plugin configuration 90% from 29 tests

readme.txt 94% from 16 tests

Often overlooked, readme.txt is one of the most important files in your plugin
Please fix the following attributes:
  • Requires at least: Invalid plugin version format
The official readme.txt is a good inspiration

doc8/doc8.php 85% from 13 tests

The principal PHP file in "DoC8" v. 1.0.0 is loaded by WordPress automatically on each request
You should first fix the following items:
  • Description: The description should be shorter than 140 characters (currently 155 characters long)
  • Text Domain: The text domain must be the same as the plugin slug, although optional since WordPress version 4.6

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | This is an overview of programming languages used in this plugin; dangerous file extensions are not allowed
Everything looks great! No dangerous files found in this plugin1,465 lines of code in 377 files:
LanguageFilesBlank linesComment linesLines of code
PHP12206291815
JavaScript3614014494
CSS41310156

PHP code Passed 2 tests

Cyclomatic complexity and code structure are the fingerprint of this plugin
There were no cyclomatic complexity issued detected
Cyclomatic complexity
Average complexity per logical line of code0.30
Average class complexity7.50
▷ Minimum class complexity5.00
▷ Maximum class complexity10.00
Average method complexity1.54
▷ Minimum method complexity1.00
▷ Maximum method complexity9.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes2
▷ Abstract classes00.00%
▷ Concrete classes2100.00%
▷ Final classes150.00%
Methods24
▷ Static methods14.17%
▷ Public methods2291.67%
▷ Protected methods28.33%
▷ Private methods00.00%
Functions29
▷ Named functions29100.00%
▷ Anonymous functions00.00%
Constants0
▷ Global constants00.00%
▷ Class constants00.00%
▷ Public constants00.00%

Plugin size Passed 2 tests

Image compression Passed 2 tests

PNG files should be compressed to save space and minimize bandwidth usage
PNG images were not found in this plugin