84% kk-blog-card

Code Review | kk blog card

WordPress plugin kk blog card scored84%from 54 tests.

About plugin

  • Plugin page: kk-blog-card
  • Plugin version: 1.3
  • PHP version: 7.4.16
  • WordPress compatibility: 4.9.4-4.9.4
  • WordPress version: 6.3.1
  • First release: Feb 23, 2018
  • Latest release: Mar 5, 2018
  • Number of updates: 21
  • Update frequency: every 0.5 days
  • Top authors: kenz60 (100%)

Code review

54 tests

User reviews

1 review

Install metrics

40+ active /1,180 total downloads

Benchmarks

Plugin footprint 83% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | Checking the installer triggered no errors
The plugin installed successfully, without throwing any errors or notices

Server metrics [RAM: ▼0.64MB] [CPU: ▼17.20ms] Passed 4 tests

Analyzing server-side resources used by kk blog card
This plugin has minimal impact on server resources
PageMemory (MB)CPU Time (ms)
Home /3.51 ▲0.0539.15 ▼1.56
Dashboard /wp-admin3.35 ▲0.0445.09 ▼5.02
Posts /wp-admin/edit.php3.46 ▲0.1048.74 ▲1.63
Add New Post /wp-admin/post-new.php3.22 ▼2.6735.04 ▼63.13
Media Library /wp-admin/upload.php3.27 ▲0.0435.39 ▲0.91

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

How much does this plugin use your filesystem and database?
This plugin installed successfully
Filesystem: 27 new files
Database: no new tables, 6 new options
New WordPress options
widget_recent-posts
widget_recent-comments
widget_theysaidso_widget
db_upgraded
can_compress_scripts
theysaidso_admin_options

Browser metrics Passed 4 tests

A check of browser resources used by kk blog card
Minimal impact on browser resources
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,806 ▲6013.24 ▼1.141.94 ▲0.1043.70 ▲0.67
Dashboard /wp-admin2,209 ▲245.84 ▼0.04102.61 ▼15.1238.74 ▼7.34
Posts /wp-admin/edit.php2,089 ▼02.05 ▲0.0338.71 ▲4.2734.81 ▲0.50
Add New Post /wp-admin/post-new.php1,545 ▲2518.54 ▼4.57623.05 ▼112.4961.46 ▲0.51
Media Library /wp-admin/upload.php1,388 ▲34.19 ▼0.0196.71 ▼1.3041.27 ▼2.34

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

🔸 Tests weight: 35 | The uninstall procedure must remove all plugin files and extra database tables
Please fix the following items
  • Zombie WordPress options detected upon uninstall: 6 options
    • theysaidso_admin_options
    • widget_recent-posts
    • can_compress_scripts
    • db_upgraded
    • widget_theysaidso_widget
    • widget_recent-comments

Smoke tests 75% from 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | Just a short smoke test targeting errors on the server (in the Apache logs)
Even though no errors were found, this is by no means an exhaustive test

SRP 50% from 2 tests

🔹 Tests weight: 20 | SRP (Single-Responsibility Principle) - PHP files must act as libraries and never output text or perform any action when accessed directly in a browser
Almost there! Just fix the following items
  • 3× PHP files trigger errors when accessed directly with GET requests:
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_shortcode() in wp-content/plugins/kk-blog-card/kk-blog-card-shortcode.php:3
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_action() in wp-content/plugins/kk-blog-card/kk-blog-card-api.php:6
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_shortcode() in wp-content/plugins/kk-blog-card/kk-blog-card-shortcode.php:3

User-side errors Passed 1 test

🔹 Test weight: 20 | This is a smoke test targeting browser errors/issues
No browser errors were detected

Optimizations

Plugin configuration 93% 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:
  • Donate link: Please fix this invalid URI: ""
You can take inspiration from this readme.txt

kk-blog-card/kk-blog-card-register.php 92% from 13 tests

The main file in "kk blog card" v. 1.3 serves as a complement to information provided in readme.txt and as the entry point to the plugin
Please take the time to fix the following:
  • Main file name: It is recommended to name the main PHP file as the plugin slug ("kk-blog-card.php" instead of "kk-blog-card-register.php")

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | A short review of files and their extensions; it is not recommended to include executable files
There were no executable files found in this plugin766 lines of code in 21 files:
LanguageFilesBlank linesComment linesLines of code
Sass290258
PHP54151209
JavaScript8196138
HTML370112
JSON10032
SVG10116
Markdown1001

PHP code Passed 2 tests

Analyzing logical lines of code, cyclomatic complexity, and other code metrics
There are no cyclomatic complexity problems detected for this plugin
Cyclomatic complexity
Average complexity per logical line of code0.38
Average class complexity15.00
▷ Minimum class complexity3.00
▷ Maximum class complexity27.00
Average method complexity4.11
▷ Minimum method complexity1.00
▷ Maximum method complexity24.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes2
▷ Abstract classes00.00%
▷ Concrete classes2100.00%
▷ Final classes00.00%
Methods9
▷ Static methods00.00%
▷ Public methods777.78%
▷ Protected methods00.00%
▷ Private methods222.22%
Functions8
▷ Named functions337.50%
▷ Anonymous functions562.50%
Constants1
▷ Global constants00.00%
▷ Class constants1100.00%
▷ Public constants1100.00%

Plugin size Passed 2 tests

Image compression Passed 2 tests

It is recommended to compress PNG files in your plugin to minimize bandwidth usage
No PNG images were found in this plugin