78% koality-io

Code Review | Website and quality monitoring (by koality.io)

WordPress plugin Website and quality monitoring (by koality.io) scored78%from 54 tests.

About plugin

  • Plugin page: koality-io
  • Plugin version: 1.4.2
  • PHP version: 7.4.16
  • WordPress compatibility: 5.4-6.4.1
  • WordPress version: 6.3.1
  • First release: Sep 4, 2021
  • Latest release: Nov 20, 2023
  • Number of updates: 26
  • Update frequency: every 31.1 days
  • Top authors: leankoala (100%)

Code review

54 tests

User reviews

1 review

Install metrics

10+ active /3,813 total downloads

Benchmarks

Plugin footprint 83% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | All plugins must install correctly, without throwing any errors, warnings, or notices
This plugin's installer ran successfully

Server metrics [RAM: ▼0.27MB] [CPU: ▼12.86ms] Passed 4 tests

A check of server-side resources used by Website and quality monitoring (by koality.io)
This plugin does not affect your website's performance
PageMemory (MB)CPU Time (ms)
Home /3.87 ▲0.4140.68 ▼1.23
Dashboard /wp-admin3.74 ▲0.4351.33 ▲0.52
Posts /wp-admin/edit.php3.79 ▲0.4351.28 ▲3.77
Add New Post /wp-admin/post-new.php3.55 ▼2.3338.39 ▼54.50
Media Library /wp-admin/upload.php3.66 ▲0.4340.46 ▲7.73
Configuration /wp-admin/admin.php?page=checks3.5735.16
Content Monitoring /wp-admin/admin.php?page=koality-settings-content3.5635.40
Security Monitoring /wp-admin/admin.php?page=koality-settings-security3.5649.32
koality.io /wp-admin/admin.php?page=koality3.5633.28
System Monitoring /wp-admin/admin.php?page=koality-settings-server3.5631.17

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

Filesystem and database footprint
No storage issues were detected
Filesystem: 262 new files
Database: no new tables, 6 new options
New WordPress options
widget_recent-comments
widget_recent-posts
theysaidso_admin_options
db_upgraded
can_compress_scripts
widget_theysaidso_widget

Browser metrics Passed 4 tests

A check of browser resources used by Website and quality monitoring (by koality.io)
Minimal impact on browser resources
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,850 ▲6314.67 ▲0.401.84 ▲0.0036.73 ▼7.11
Dashboard /wp-admin2,230 ▲535.64 ▼0.0097.03 ▼3.5241.26 ▼5.68
Posts /wp-admin/edit.php2,135 ▲352.02 ▲0.0844.11 ▲6.5137.48 ▲3.14
Add New Post /wp-admin/post-new.php1,559 ▲3320.74 ▼2.51688.25 ▲70.8853.20 ▼0.47
Media Library /wp-admin/upload.php1,435 ▲324.14 ▼0.0694.66 ▼3.4743.69 ▼0.41
Configuration /wp-admin/admin.php?page=checks9982.1227.4831.95
Content Monitoring /wp-admin/admin.php?page=koality-settings-content8392.0325.8730.71
Security Monitoring /wp-admin/admin.php?page=koality-settings-security8681.9731.0338.65
koality.io /wp-admin/admin.php?page=koality8622.1623.2328.49
System Monitoring /wp-admin/admin.php?page=koality-settings-server8282.0026.0026.45

Uninstaller [IO: ▲0.00MB] [DB: ▲0.00MB] 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
  • The uninstall procedure has failed, leaving 7 options in the database
    • widget_recent-comments
    • can_compress_scripts
    • theysaidso_admin_options
    • db_upgraded
    • koality_api_key
    • widget_recent-posts
    • widget_theysaidso_widget

Smoke tests 50% from 4 tests

Server-side errors 0% from 1 test

🔹 Test weight: 20 | This is a short smoke test looking for server-side errors
These server-side errors were triggered
  • 2 occurences, only the last one shown
    • > GET request to /wp-admin/admin.php?page=koality-settings-content
    • > request to
    • > Notice in wp-config.php+20
    Undefined index: REQUEST_METHOD

SRP 50% from 2 tests

🔹 Tests weight: 20 | The single-responsibility principle applies for WordPress plugins as well - please make sure your PHP files perform no actions when accessed directly
Please fix the following items
  • 102× GET requests to PHP files have triggered server-side errors or warnings (only 10 are shown):
    • > PHP Fatal error
      Uncaught Error: Interface 'Leankoala\\HealthFoundationBase\\Check\\Check' not found in wp-content/plugins/koality-io/vendor/leankoala/healthfoundationchecks/src/Database/Mysql/Slave/SlaveStatusFieldCheck.php:8
    • > PHP Fatal error
      Uncaught Error: Interface 'Leankoala\\HealthFoundationBase\\Check\\Check' not found in wp-content/plugins/koality-io/vendor/leankoala/healthfoundationchecks/src/System/NumberProcessesCheck.php:9
    • > PHP Fatal error
      Uncaught Error: Class 'GuzzleHttp\\Exception\\BadResponseException' not found in wp-content/plugins/koality-io/vendor/guzzlehttp/guzzle/src/Exception/ServerException.php:8
    • > PHP Fatal error
      Uncaught Error: Interface 'GuzzleHttp\\Promise\\PromiseInterface' not found in wp-content/plugins/koality-io/vendor/guzzlehttp/promises/src/RejectedPromise.php:15
    • > PHP Fatal error
      Uncaught Error: Interface 'Leankoala\\HealthFoundationBase\\Check\\Check' not found in wp-content/plugins/koality-io/vendor/leankoala/healthfoundationchecks/src/Docker/Container/ContainerIsRunningCheck.php:9
    • > PHP Fatal error
      Uncaught Error: Class 'Leankoala\\HealthFoundationChecks\\BasicCheck' not found in wp-content/plugins/koality-io/vendor/leankoala/healthfoundationchecks/src/Files/Content/NumberOfLinesCheck.php:9
    • > PHP Fatal error
      Uncaught Error: Class 'GuzzleHttp\\Exception\\RequestException' not found in wp-content/plugins/koality-io/vendor/guzzlehttp/guzzle/src/Exception/TooManyRedirectsException.php:5
    • > PHP Fatal error
      Uncaught Error: Interface 'Leankoala\\HealthFoundationBase\\Check\\Check' not found in wp-content/plugins/koality-io/vendor/leankoala/healthfoundationchecks/src/Basic/StaticCheck.php:15
    • > PHP Fatal error
      Uncaught Error: Interface 'Psr\\Http\\Message\\StreamInterface' not found in wp-content/plugins/koality-io/vendor/guzzlehttp/psr7/src/CachingStream.php:13
    • > PHP Fatal error
      Uncaught Error: Call to undefined function settings_errors() in wp-content/plugins/koality-io/src/Admin/partials/settings-woocommerce.php:26

User-side errors Passed 1 test

🔹 Test weight: 20 | This is a smoke test targeting browser errors/issues
Everything seems fine on the user side

Optimizations

Plugin configuration 90% from 29 tests

readme.txt 94% from 16 tests

Don't ignore readme.txt as it is the file that instructs WordPress.org on how to present your plugin to the world
Attributes that require attention:
  • Contributors: The plugin contributors field is not present
You can take inspiration from this readme.txt

koality-io/koality-io.php 85% from 13 tests

"Website and quality monitoring (by koality.io)" version 1.4.2's main PHP file describes plugin functionality and also serves as the entry point to any WordPress functionality
Please take the time to fix the following:
  • Requires at least: The required version number did not match the one declared in readme.txt ("6.0.0" instead of "5.4")
  • Text Domain: Since WordPress version 4.6 the text domain is optional; if specified, it must be the same as the plugin slug

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | Executable files are not allowed as they can serve as attack vectors
No dangerous file extensions were detected18,737 lines of code in 235 files:
LanguageFilesBlank linesComment linesLines of code
PHP2013,0676,76113,416
Markdown201,48304,008
JSON14001,313

PHP code Passed 2 tests

An overview of cyclomatic complexity and code structure
Great job! No cyclomatic complexity issues were detected in this plugin
Cyclomatic complexity
Average complexity per logical line of code0.39
Average class complexity9.77
▷ Minimum class complexity1.00
▷ Maximum class complexity99.00
Average method complexity2.55
▷ Minimum method complexity1.00
▷ Maximum method complexity27.00
Code structure
Namespaces53
Interfaces33
Traits3
Classes140
▷ Abstract classes75.00%
▷ Concrete classes13395.00%
▷ Final classes3526.32%
Methods1,006
▷ Static methods17417.30%
▷ Public methods83983.40%
▷ Protected methods212.09%
▷ Private methods14614.51%
Functions108
▷ Named functions1513.89%
▷ Anonymous functions9386.11%
Constants152
▷ Global constants21.32%
▷ Class constants15098.68%
▷ Public constants13992.67%

Plugin size Passed 2 tests

Image compression Passed 2 tests

Using a strong compression for your PNG files is a great way to speed-up your plugin
No PNG files were detected