10% whale-kit

Code Review | Whale-Kit

WordPress plugin Whale-Kit scored10%from 54 tests.

About plugin

  • Plugin page: whale-kit
  • Plugin version: 2.0
  • PHP compatiblity: 5.4+
  • PHP version: 7.4.16
  • WordPress version: 6.3.1
  • First release: Jul 26, 2014
  • Latest release: Jan 15, 2022
  • Number of updates: 16
  • Update frequency: every 176.4 days
  • Top authors: stur (100%)

Code review

54 tests

User reviews

1 review

Install metrics

10+ active /1,116 total downloads

Benchmarks

Plugin footprint 58% from 16 tests

Installer 0% from 1 test

🔺 Critical test (weight: 50) | All plugins must install correctly, without throwing any errors, warnings, or notices
Please fix the following installer errors
  • This plugin did not install gracefully
    • > Warning in wp-content/plugins/whale-kit/whale-kit.php+18
    require_once(wp-content/plugins/whale-kit/wk-tree.php): failed to open stream: No such file or directory

Server metrics [RAM: ▲0.00MB] [CPU: ▼4.05ms] Passed 4 tests

A check of server-side resources used by Whale-Kit
Server-side resource usage in normal parameters
PageMemory (MB)CPU Time (ms)
Home /3.46 ▲0.0048.43 ▲6.55
Dashboard /wp-admin3.31 ▲0.0053.40 ▲1.71
Posts /wp-admin/edit.php3.36 ▲0.0048.32 ▼2.99
Add New Post /wp-admin/post-new.php5.89 ▲0.0084.88 ▼16.37
Media Library /wp-admin/upload.php3.23 ▲0.0041.10 ▲1.45

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

Filesystem and database footprint
This plugin installed successfully
Filesystem: 8 new files
Database: no new tables, 6 new options
New WordPress options
can_compress_scripts
db_upgraded
widget_theysaidso_widget
widget_recent-posts
theysaidso_admin_options
widget_recent-comments

Browser metrics Passed 4 tests

Whale-Kit: an overview of browser usage
Normal browser usage
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,789 ▲2814.16 ▼0.191.69 ▲0.1544.12 ▲0.84
Dashboard /wp-admin2,195 ▲185.56 ▼0.0993.27 ▲3.5038.36 ▼6.42
Posts /wp-admin/edit.php2,100 ▼02.06 ▲0.0735.04 ▼1.9237.53 ▲5.28
Add New Post /wp-admin/post-new.php1,528 ▲223.34 ▼0.15684.26 ▼7.6153.59 ▼6.72
Media Library /wp-admin/upload.php1,403 ▲64.18 ▼0.07109.77 ▼3.3846.65 ▲0.61

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

🔸 Tests weight: 35 | Verifying that this plugin uninstalls completely without leaving any traces
You still need to fix the following
  • The uninstall procedure has failed, leaving 6 options in the database
    • widget_recent-posts
    • db_upgraded
    • can_compress_scripts
    • widget_recent-comments
    • widget_theysaidso_widget
    • theysaidso_admin_options

Smoke tests 50% from 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | A shallow check that no server-side errors were triggered
Even though no errors were found, this is by no means an exhaustive test

SRP 0% from 2 tests

🔹 Tests weight: 20 | It is important to ensure that your PHP files perform no action when accessed directly, respecting the single-responsibility principle
Please take a closer look at the following
  • 1× GET requests to PHP files return non-empty strings:
    • > /wp-content/plugins/whale-kit/wk-terms.php
  • 2× PHP files trigger server errors when accessed directly:
    • > PHP Fatal error
      Uncaught Error: Call to undefined function remove_filter() in wp-content/plugins/whale-kit/whale-kit.php:16
    • > PHP Fatal error
      Uncaught Error: Class 'WK_tree' not found in wp-content/plugins/whale-kit/wk-posts.php:40

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

The readme.txt file uses markdown syntax to describe your plugin to the world
8 plugin tags: wp_query, posts, get_pages, taxonomies, categories...

whale-kit/whale-kit.php 92% from 13 tests

The main PHP script in "Whale-Kit" version 2.0 is automatically included on every request by WordPress
The following require your attention:
  • Description: Please keep the plugin description shorter than 140 characters (currently 604 characters long)

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | A short check of programming languages and file extensions; no executable files are allowed
No dangerous file extensions were detected372 lines of code in 3 files:
LanguageFilesBlank linesComment linesLines of code
PHP399180372

PHP code Passed 2 tests

A brief analysis of cyclomatic complexity and code structure for 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.57
Average class complexity34.50
▷ Minimum class complexity17.00
▷ Maximum class complexity52.00
Average method complexity10.57
▷ Minimum method complexity3.00
▷ Maximum method complexity27.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes2
▷ Abstract classes00.00%
▷ Concrete classes2100.00%
▷ Final classes00.00%
Methods7
▷ Static methods00.00%
▷ Public methods7100.00%
▷ Protected methods00.00%
▷ Private methods00.00%
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

PNG files should be compressed to save space and minimize bandwidth usage
4 PNG files occupy 0.16MB with 0.11MB in potential savings
Potential savings
Compression of 4 random PNG files using pngquant
FileSize - originalSize - compressedSavings
screenshot-3.png5.14KB2.16KB▼ 58.03%
screenshot-2.png8.67KB3.39KB▼ 60.92%
screenshot-1.png60.29KB19.33KB▼ 67.94%
screenshot-4.png92.66KB21.63KB▼ 76.65%