93% dokiv-sharing

Code Review | Dokiv Sharing for WP

WordPress plugin Dokiv Sharing for WP scored 93% from 54 tests.

About plugin

  • Plugin page: dokiv-sharing
  • Plugin version: 1.1.0
  • PHP compatiblity: 5.6+
  • PHP version: 7.4.16
  • WordPress compatibility: 3.0-4.9
  • WordPress version: 5.8.1
  • First release: Sep 26, 2018
  • Latest release: Apr 19, 2019
  • Number of updates: 8
  • Update frequency: every 28.3 days
  • Top authors: richardlikipe (100%)

Code review

54 tests

User reviews

1 review

Install metrics

10+ active / 371 total downloads

Benchmarks

Plugin footprint Passed 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | Checking the installer triggered no errors
Installer ran successfully

Server metrics [RAM: ▲0.03MB] [CPU: ▼138.36ms] Passed 4 tests

This is a short check of server-side resources used by Dokiv Sharing for WP
No issues were detected with server-side resource usage
PageMemory (MB)CPU Time (ms)
Home /2.87 ▲0.0432.00 ▼3.97
Dashboard /wp-admin3.09 ▲0.0445.20 ▼0.20
Posts /wp-admin/edit.php3.14 ▲0.0444.48 ▼0.20
Add New Post /wp-admin/post-new.php5.46 ▲0.0396.12 ▼543.82
Media Library /wp-admin/upload.php3.03 ▲0.0333.31 ▼5.46

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

Filesystem and database footprint
This plugin installed successfully
Filesystem: 10 new files
Database: no new tables, no new options

Browser metrics Passed 4 tests

Dokiv Sharing for WP: an overview of browser usage
This plugin renders optimally with no browser resource issues detected
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /3,814 ▲21816.37 ▲0.5314.51 ▲4.7246.19 ▼2.43
Dashboard /wp-admin2,970 ▲395.87 ▼0.02156.06 ▲4.29105.25 ▼5.26
Posts /wp-admin/edit.php2,739 ▼02.69 ▼0.0067.64 ▲2.6190.00 ▼1.96
Add New Post /wp-admin/post-new.php1,498 ▼17418.88 ▼0.15358.07 ▼15.80105.26 ▼8.28
Media Library /wp-admin/upload.php1,810 ▲35.00 ▼0.01161.06 ▲9.73110.24 ▼10.19

Uninstaller [IO: ▲0.00MB] [DB: ▲0.00MB] Passed 4 tests

🔸 Tests weight: 35 | Verifying that this plugin uninstalls completely without leaving any traces
Uninstall script ran successfully

Smoke tests 75% from 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | A smoke test targeting server-side errors
The smoke test was a success, however most plugin functionality was not tested

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
Please 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 add_filter() in wp-content/plugins/dokiv-sharing/dokiv_sharing.php:31
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_action() in wp-content/plugins/dokiv-sharing/libs/menu_item_custom_fields.php:46
    • > PHP Fatal error
      Uncaught Error: Class 'Walker_Nav_Menu_Edit' not found in wp-content/plugins/dokiv-sharing/libs/custom_walker_edit.php:12

User-side errors Passed 1 test

🔹 Test weight: 20 | A shallow check that no browser errors were triggered
There were no browser issues found

Optimizations

Plugin configuration 90% 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
2 plugin tags: doki share, dokiv

dokiv-sharing/dokiv_sharing.php 77% from 13 tests

The main file in "Dokiv Sharing for WP" v. 1.1.0 serves as a complement to information provided in readme.txt and as the entry point to the plugin
It is important to fix the following:
  • Domain Path: The domain path folder was not found ("/languages")
  • Text Domain: If you choose to specify the text domain, it must be the same as the plugin slug; optional since WordPress version 4.6
  • Main file name: Please rename the main PHP file in this plugin to the plugin slug ("dokiv-sharing.php" instead of "dokiv_sharing.php")

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 plugin228 lines of code in 7 files:
LanguageFilesBlank linesComment linesLines of code
PHP337147128
JavaScript311299
CSS1001

PHP code Passed 2 tests

This is a very shot review of cyclomatic complexity and code structure
All good! No complexity issues found
Cyclomatic complexity
Average complexity per logical line of code0.23
Average class complexity4.00
▷ Minimum class complexity1.00
▷ Maximum class complexity7.00
Average method complexity2.00
▷ Minimum method complexity1.00
▷ Maximum method complexity6.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes2
▷ Abstract classes00.00%
▷ Concrete classes2100.00%
▷ Final classes00.00%
Methods6
▷ Static methods466.67%
▷ Public methods583.33%
▷ Protected methods116.67%
▷ Private methods00.00%
Functions6
▷ Named functions6100.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
2 PNG files occupy 0.01MB with 0.00MB in potential savings
Potential savings
Compression of 2 random PNG files using pngquant
FileSize - originalSize - compressedSavings
assets/js/dokiv-button.png0.74KB0.73KB▼ 0.66%
assets/js/dokiv-button-box.png8.47KB3.66KB▼ 56.86%