79% docular

Code Review | Docular. Create GDPR-ready privacy policies and terms & conditions for your site quickly and easily.

WordPress plugin Docular. Create GDPR-ready privacy policies and terms & conditions for your site quickly and easily. scored79%from 54 tests.

About plugin

  • Plugin page: docular
  • Plugin version: 1.1.0
  • PHP version: 7.4.16
  • WordPress compatibility: 3.0.1-5.2.3
  • WordPress version: 6.3.1
  • First release: Apr 16, 2018
  • Latest release: Sep 10, 2019
  • Number of updates: 5
  • Update frequency: every 102.4 days
  • Top authors: docular (100%)

Code review

54 tests

User reviews

1 review

Install metrics

50+ active /2,305 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.12MB] [CPU: ▼5.10ms] Passed 4 tests

An overview of server-side resources used by Docular. Create GDPR-ready privacy policies and terms & conditions for your site quickly and easily.
This plugin does not affect your website's performance
PageMemory (MB)CPU Time (ms)
Home /3.59 ▲0.1241.68 ▼2.40
Dashboard /wp-admin3.42 ▲0.1254.27 ▲0.41
Posts /wp-admin/edit.php3.54 ▲0.1852.38 ▼5.02
Add New Post /wp-admin/post-new.php6.02 ▲0.1486.98 ▼13.23
Media Library /wp-admin/upload.php3.34 ▲0.1237.22 ▲0.25

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

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

Browser metrics Passed 4 tests

An overview of browser requirements for Docular. Create GDPR-ready privacy policies and terms & conditions for your site quickly and easily.
Normal browser usage
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,895 ▲13413.38 ▼0.557.96 ▲6.1746.38 ▲4.61
Dashboard /wp-admin2,215 ▲355.57 ▼0.0999.45 ▲8.6942.98 ▲3.60
Posts /wp-admin/edit.php2,126 ▲232.00 ▼0.0238.54 ▼3.3233.94 ▼2.96
Add New Post /wp-admin/post-new.php1,547 ▲2123.42 ▲0.34671.85 ▼34.6463.13 ▲6.76
Media Library /wp-admin/upload.php1,420 ▲294.18 ▼0.10100.28 ▼0.6144.89 ▲2.96

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

🔸 Tests weight: 35 | It is important to correctly uninstall your plugin, without leaving any traces
It is recommended to fix the following
  • This plugin does not fully uninstall, leaving 6 options in the database
    • widget_theysaidso_widget
    • can_compress_scripts
    • widget_recent-posts
    • widget_recent-comments
    • db_upgraded
    • theysaidso_admin_options

Smoke tests 50% from 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | A smoke test targeting server-side errors
Good news, no errors were detected

SRP 0% 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
Please take a closer look at the following
  • 1× PHP files output non-empty strings when accessed directly via GET requests:
    • > /wp-content/plugins/docular/public/partials/docular-public-display.php
  • 1× PHP files trigger server errors when accessed directly:
    • > PHP Fatal error
      Uncaught Error: Call to undefined function get_option() in wp-content/plugins/docular/admin/partials/docular-admin-page-settings.php:32

User-side errors Passed 1 test

🔹 Test weight: 20 | A shallow check that no browser errors were triggered
Everything seems fine on the user side

Optimizations

Plugin configuration Passed 29 tests

readme.txt Passed 16 tests

The readme.txt file describes your plugin functionality and requirements and it is parsed to prepare the your plugin's listing
10 plugin tags: docular, terms, gdpr, disclaimer, conditions...

docular/docular.php Passed 13 tests

This is the main PHP file of "Docular. Create GDPR-ready privacy policies and terms & conditions for your site quickly and easily." version 1.1.0, providing information about the plugin in the header fields and serving as the principal entry point to the plugin's functions
119 characters long description:
Add GDPR-friendly privacy policies and terms and conditions to your website, using the FREE Docular document generator.

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | This is an overview of file extensions present in this plugin and a short test that no dangerous files are bundled with this plugin
Success! There were no dangerous files found in this plugin912 lines of code in 16 files:
LanguageFilesBlank linesComment linesLines of code
PHP12257640557
CSS2898250
JavaScript24927105

PHP code Passed 2 tests

A brief analysis of cyclomatic complexity and code structure for this plugin
No complexity issues detected
Cyclomatic complexity
Average complexity per logical line of code0.23
Average class complexity8.71
▷ Minimum class complexity1.00
▷ Maximum class complexity40.00
Average method complexity2.46
▷ Minimum method complexity1.00
▷ Maximum method complexity13.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes7
▷ Abstract classes00.00%
▷ Concrete classes7100.00%
▷ Final classes00.00%
Methods37
▷ Static methods25.41%
▷ Public methods3286.49%
▷ Protected methods00.00%
▷ Private methods513.51%
Functions3
▷ Named functions3100.00%
▷ Anonymous functions00.00%
Constants1
▷ Global constants1100.00%
▷ Class constants00.00%
▷ Public constants00.00%

Plugin size Passed 2 tests

Image compression Passed 2 tests

All PNG images should be compressed to minimize bandwidth usage for end users
5 PNG files occupy 0.36MB with 0.07MB in potential savings
Potential savings
Compression of 5 random PNG files using pngquant
FileSize - originalSize - compressedSavings
admin/assets/document_key.png43.84KB41.58KB▼ 5.16%
admin/assets/docular_logo.png5.13KB2.76KB▼ 46.26%
admin/assets/docular_roundel.png1.11KB0.65KB▼ 41.93%
admin/assets/docular_logo_black.png9.95KB9.30KB▼ 6.59%
admin/assets/banner.png312.13KB316.92KB0.00%