84% mrkv-vchasno-kasa

Code Review | Vchasno Kasa

WordPress plugin Vchasno Kasa scored84%from 54 tests.

About plugin

  • Plugin page: mrkv-vchasno-kasa
  • Plugin version: 0.8.1
  • PHP compatiblity: 7.1+
  • PHP version: 7.4.16
  • WordPress compatibility: 5.2-6.3
  • WordPress version: 6.3.1
  • First release: Dec 13, 2022
  • Latest release: Nov 10, 2023
  • Number of updates: 13
  • Update frequency: every 25.5 days
  • Top authors: bandido (100%)

Code review

54 tests

User reviews

1 review

Install metrics

10+ active /577 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
The plugin installed gracefully, with no errors

Server metrics [RAM: ▼0.01MB] [CPU: ▼9.72ms] Passed 4 tests

A check of server-side resources used by Vchasno Kasa
This plugin has minimal impact on server resources
PageMemory (MB)CPU Time (ms)
Home /3.46 ▲0.0034.90 ▼6.02
Dashboard /wp-admin3.31 ▼0.0443.69 ▼16.30
Posts /wp-admin/edit.php3.36 ▲0.0049.81 ▲3.14
Add New Post /wp-admin/post-new.php5.89 ▲0.0082.06 ▼15.24
Media Library /wp-admin/upload.php3.23 ▲0.0032.29 ▼1.32

Server storage [IO: ▲0.12MB] [DB: ▲0.07MB] Passed 3 tests

Input-output and database impact of this plugin
This plugin was installed successfully
Filesystem: 19 new files
Database: no new tables, 6 new options
New WordPress options
db_upgraded
widget_recent-posts
theysaidso_admin_options
widget_theysaidso_widget
can_compress_scripts
widget_recent-comments

Browser metrics Passed 4 tests

An overview of browser requirements for Vchasno Kasa
Normal browser usage
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,790 ▲1814.14 ▼0.621.61 ▼0.3036.93 ▼6.28
Dashboard /wp-admin2,198 ▲185.62 ▲0.0089.25 ▼8.3239.65 ▼7.10
Posts /wp-admin/edit.php2,103 ▲31.95 ▼0.2033.96 ▼4.2630.66 ▼2.58
Add New Post /wp-admin/post-new.php1,526 ▼1922.91 ▼2.24674.88 ▲27.0052.27 ▼16.44
Media Library /wp-admin/upload.php1,403 ▲64.21 ▲0.0098.49 ▼4.7442.06 ▼2.11

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

🔸 Tests weight: 35 | All plugins must uninstall correctly, removing their source code and extra database tables they might have created
These items require your attention
  • Zombie WordPress options were found after uninstall: 6 options
    • widget_recent-comments
    • widget_recent-posts
    • can_compress_scripts
    • db_upgraded
    • widget_theysaidso_widget
    • theysaidso_admin_options

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
Everything seems fine, however this is by no means 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
Please take a closer look at the following
  • 6× GET requests to PHP files have triggered server-side errors or warnings:
    • > PHP Fatal error
      Uncaught Error: Call to undefined function plugin_dir_path() in wp-content/plugins/mrkv-vchasno-kasa/classes/mrkv-connect-data.php:3
    • > PHP Fatal error
      Uncaught Error: Call to undefined function WC() in wp-content/plugins/mrkv-vchasno-kasa/templates/mrkv-setting-page-template.php:3
    • > PHP Fatal error
      Uncaught Error: Call to undefined function plugin_dir_path() in wp-content/plugins/mrkv-vchasno-kasa/classes/mrkv-vchasno-kasa-api.php:3
    • > PHP Fatal error
      Uncaught Error: Call to undefined function plugin_dir_path() in wp-content/plugins/mrkv-vchasno-kasa/classes/mrkv-shift.php:3
    • > PHP Fatal error
      Uncaught Error: Call to undefined function plugin_dir_path() in wp-content/plugins/mrkv-vchasno-kasa/classes/mrkv-vchasno-kasa-receipt.php:3
    • > PHP Fatal error
      Uncaught Error: Call to undefined function plugin_dir_path() in wp-content/plugins/mrkv-vchasno-kasa/templates/mrkv-widget-template.php:3

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)
There were no browser issues found

Optimizations

Plugin configuration 96% from 29 tests

readme.txt Passed 16 tests

Often overlooked, readme.txt is one of the most important files in your plugin
2 plugin tags: woocommerce, vchasno kasa

mrkv-vchasno-kasa/mrkv-vchasno-kasa.php 92% from 13 tests

The main file in "Vchasno Kasa" v. 0.8.1 serves as a complement to information provided in readme.txt and as the entry point to the plugin
Please make the necessary changes and fix the following:
  • Domain Path: The domain path points to a folder that does not exist ("/languages")

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | Executable files are considered dangerous and should not be included with any WordPress plugin
There were no executable files found in this plugin1,048 lines of code in 16 files:
LanguageFilesBlank linesComment linesLines of code
PHP10234562956
CSS23869
SVG20020
Markdown1002
JavaScript1111

PHP code Passed 2 tests

Cyclomatic complexity and code structure are the fingerprint of this plugin
Although this was not an exhaustive test, there were no cyclomatic complexity issues detected
Cyclomatic complexity
Average complexity per logical line of code0.33
Average class complexity10.71
▷ Minimum class complexity1.00
▷ Maximum class complexity33.00
Average method complexity2.51
▷ Minimum method complexity1.00
▷ Maximum method complexity25.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes7
▷ Abstract classes00.00%
▷ Concrete classes7100.00%
▷ Final classes00.00%
Methods45
▷ Static methods00.00%
▷ Public methods3782.22%
▷ Protected methods00.00%
▷ Private methods817.78%
Functions4
▷ Named functions00.00%
▷ Anonymous functions4100.00%
Constants8
▷ Global constants00.00%
▷ Class constants8100.00%
▷ Public constants8100.00%

Plugin size Passed 2 tests

Image compression Passed 2 tests

PNG files should be compressed to save space and minimize bandwidth usage
1 compressed PNG file occupies 0.00MB
Potential savings
Compression of 1 random PNG file using pngquant
FileSize - originalSize - compressedSavings
assets/imgs/chosen-sprite.png0.53KB0.88KB0.00%