77% kagg-fast-post-generator

Code Review | KAGG Generator

WordPress plugin KAGG Generator scored77%from 54 tests.

About plugin

  • Plugin page: kagg-fast-post-ge...
  • Plugin version: 1.9.0
  • PHP compatiblity: 7.0+
  • PHP version: 7.4.16
  • WordPress compatibility: 5.3-6.3
  • WordPress version: 6.3.1
  • First release: Apr 20, 2022
  • Latest release: Aug 2, 2023
  • Number of updates: 12
  • Update frequency: every 39.1 days
  • Top authors: kaggdesign (100%)

Code review

54 tests

User reviews

4 reviews

Install metrics

10+ active /1,418 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 successfully, without throwing any errors or notices

Server metrics [RAM: ▲0.22MB] [CPU: ▼1.49ms] Passed 4 tests

A check of server-side resources used by KAGG Generator
Normal server usage
PageMemory (MB)CPU Time (ms)
Home /3.52 ▲0.0641.95 ▼2.52
Dashboard /wp-admin3.62 ▲0.3149.27 ▲1.29
Posts /wp-admin/edit.php3.67 ▲0.3152.15 ▼1.08
Add New Post /wp-admin/post-new.php6.16 ▲0.2788.36 ▼3.65
Media Library /wp-admin/upload.php3.48 ▲0.2543.16 ▲9.43
KAGG Generator /wp-admin/tools.php?page=kagg-generator3.4635.23

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

A short overview of filesystem and database impact
This plugin was installed successfully
Filesystem: 29 new files
Database: no new tables, 6 new options
New WordPress options
widget_recent-posts
can_compress_scripts
widget_recent-comments
theysaidso_admin_options
db_upgraded
widget_theysaidso_widget

Browser metrics Passed 4 tests

KAGG Generator: an overview of browser usage
This plugin has a minimal impact on browser resources
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,813 ▲6713.19 ▼1.241.62 ▼0.0743.08 ▲3.64
Dashboard /wp-admin2,219 ▲314.95 ▼0.91106.62 ▼6.6954.02 ▲8.01
Posts /wp-admin/edit.php2,102 ▲162.05 ▲0.0236.88 ▼2.2035.53 ▼2.57
Add New Post /wp-admin/post-new.php1,679 ▲16521.89 ▲4.36763.26 ▲117.3654.11 ▲2.67
Media Library /wp-admin/upload.php1,401 ▲164.14 ▼0.09100.65 ▼1.2748.38 ▲5.59
KAGG Generator /wp-admin/tools.php?page=kagg-generator8852.0726.1125.95

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
The following items require your attention
  • Zombie WordPress options were found after uninstall: 6 options
    • widget_recent-comments
    • theysaidso_admin_options
    • widget_theysaidso_widget
    • widget_recent-posts
    • can_compress_scripts
    • db_upgraded

Smoke tests 50% from 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | This is a short smoke test looking for server-side errors
Everything seems fine, however this is by no means an exhaustive test

SRP 0% 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
Please fix the following
  • 1× GET requests to PHP files return non-empty strings:
    • > /wp-content/plugins/kagg-fast-post-generator/src/php/ajax.php
  • 4× GET requests to PHP files trigger server-side errors or Error 500 responses:
    • > PHP Fatal error
      Uncaught Error: Class 'KAGG\\Generator\\Generator\\Item' not found in wp-content/plugins/kagg-fast-post-generator/src/php/Generator/Comment.php:17
    • > PHP Fatal error
      Uncaught Error: Class 'KAGG\\Generator\\Generator\\Item' not found in wp-content/plugins/kagg-fast-post-generator/src/php/Generator/User.php:18
    • > PHP Fatal error
      Uncaught Error: Class 'KAGG\\Generator\\Generator\\Post' not found in wp-content/plugins/kagg-fast-post-generator/src/php/Generator/Page.php:13
    • > PHP Fatal error
      Uncaught Error: Class 'KAGG\\Generator\\Generator\\Item' not found in wp-content/plugins/kagg-fast-post-generator/src/php/Generator/Post.php:18

User-side errors Passed 1 test

🔹 Test weight: 20 | This is just a short smoke test looking for browser issues
No browser issues were found

Optimizations

Plugin configuration 83% from 29 tests

readme.txt Passed 16 tests

It's important to format your readme.txt file correctly as it is parsed for the public listing of your plugin
4 plugin tags: generate posts, generate pages, bulk generate, development

kagg-fast-post-generator/plugin.php 62% from 13 tests

The main file in "KAGG Generator" v. 1.9.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:
  • 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
  • Requires PHP: Required version must match the one declared in readme.txt ("5.6" instead of "7.0")
  • Main file name: The principal plugin file should be the same as the plugin slug ("kagg-fast-post-generator.php" instead of "plugin.php")
  • Domain Path: The domain path points to an invalid folder, "/languages/" does not exist
  • Requires at least: Required version must match the one declared in readme.txt ("5.0" instead of "5.3")

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | There should be no dangerous file extensions present in any WordPress plugin
No dangerous file extensions were detected3,266 lines of code in 25 files:
LanguageFilesBlank linesComment linesLines of code
PHP225841,4773,090
JavaScript13421148
CSS15023
JSON1005

PHP code Passed 2 tests

An overview of cyclomatic complexity and code structure
There are no cyclomatic complexity problems detected for this plugin
Cyclomatic complexity
Average complexity per logical line of code0.31
Average class complexity17.33
▷ Minimum class complexity1.00
▷ Maximum class complexity56.00
Average method complexity2.92
▷ Minimum method complexity1.00
▷ Maximum method complexity23.00
Code structure
Namespaces4
Interfaces0
Traits0
Classes15
▷ Abstract classes16.67%
▷ Concrete classes1493.33%
▷ Final classes00.00%
Methods132
▷ Static methods3123.48%
▷ Public methods8665.15%
▷ Protected methods1612.12%
▷ Private methods3022.73%
Functions3
▷ Named functions00.00%
▷ Anonymous functions3100.00%
Constants21
▷ Global constants419.05%
▷ Class constants1780.95%
▷ Public constants17100.00%

Plugin size Passed 2 tests

Image compression Passed 2 tests

All PNG images should be compressed to minimize bandwidth usage for end users
1 PNG file occupies 0.00MB with 0.00MB in potential savings
Potential savings
Compression of 1 random PNG file using pngquant
FileSize - originalSize - compressedSavings
assets/images/icon-16x16.png2.06KB0.94KB▼ 54.16%