10% kickpress

Code Review | KickPress

WordPress plugin KickPress scored10%from 54 tests.

About plugin

  • Plugin page: kickpress
  • Plugin version: 0.3.5
  • PHP version: 7.4.16
  • WordPress compatibility: 3.2-4.4.2
  • WordPress version: 6.3.1
  • First release: Aug 20, 2011
  • Latest release: Feb 20, 2016
  • Number of updates: 367
  • Update frequency: every 4.7 days
  • Top authors: rocketwood (54.5%)jascott (35.42%)brettgfitzgerald (10.63%)

Code review

54 tests

User reviews

1 review

Install metrics

10+ active /4,432 total downloads

Benchmarks

Plugin footprint 58% from 16 tests

Installer 0% from 1 test

🔺 Critical test (weight: 50) | Checking the installer triggered no errors
The following installer errors require your attention
  • The plugin did not install without errors
    • > Parse error in wp-content/plugins/kickpress/kickpress-functions.php+991
    syntax error, unexpected 'new' (T_NEW)

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

A check of server-side resources used by KickPress
Normal server usage
PageMemory (MB)CPU Time (ms)
Home /3.46 ▲0.0043.25 ▲7.29
Dashboard /wp-admin3.31 ▲0.0045.07 ▲1.78
Posts /wp-admin/edit.php3.36 ▲0.0044.95 ▲3.84
Add New Post /wp-admin/post-new.php5.89 ▲0.0082.43 ▼21.28
Media Library /wp-admin/upload.php3.23 ▲0.0034.39 ▼1.45

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

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

Browser metrics Passed 4 tests

KickPress: an overview of browser usage
Normal browser usage
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,800 ▲4313.22 ▼1.161.79 ▼0.3142.99 ▲5.84
Dashboard /wp-admin2,209 ▲205.02 ▲0.05103.79 ▼20.4139.23 ▼8.08
Posts /wp-admin/edit.php2,086 ▼32.00 ▼0.0134.00 ▼8.4334.83 ▲0.28
Add New Post /wp-admin/post-new.php1,533 ▼023.21 ▲0.20654.26 ▲67.3454.70 ▼5.84
Media Library /wp-admin/upload.php1,391 ▼04.19 ▼0.0398.06 ▼4.5342.13 ▼2.31

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

🔸 Tests weight: 35 | Checking the uninstaller removed all traces of the plugin
You still need to fix the following
  • Zombie WordPress options detected upon uninstall: 6 options
    • theysaidso_admin_options
    • widget_recent-comments
    • can_compress_scripts
    • db_upgraded
    • widget_recent-posts
    • widget_theysaidso_widget

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
The smoke test was a success, however most plugin functionality was not tested

SRP 0% 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
Almost there! Just fix the following items
  • 4× PHP files perform the task of outputting text when accessed with GET requests:
    • > /wp-content/plugins/kickpress/examples/kickpress-authentication-test.php
    • > /wp-content/plugins/kickpress/examples/oauth/kickpress-oauth-authorize.php
    • > /wp-content/plugins/kickpress/kickpress-schema.php
    • > /wp-content/plugins/kickpress/kickpress-barcode.php
  • 85× PHP files trigger server errors when accessed directly (only 10 are shown):
    • > PHP Fatal error
      Uncaught Error: Class 'kickpress_form_elements' not found in wp-content/plugins/kickpress/elements/class-list.php:3
    • > PHP Fatal error
      Uncaught Error: Class 'kickpress_form_elements' not found in wp-content/plugins/kickpress/elements/class-field-sort-direction.php:3
    • > PHP Fatal error
      Uncaught Error: Class 'kickpress_form_elements' not found in wp-content/plugins/kickpress/elements/class-password.php:3
    • > PHP Fatal error
      Uncaught Error: Class 'kickpress_form_elements' not found in wp-content/plugins/kickpress/elements/class-post-type-fields.php:3
    • > PHP Notice
      Trying to get property 'posts' of non-object in wp-content/plugins/kickpress/kickpress.php on line 47
    • > PHP Fatal error
      Uncaught Error: Class 'kickpress_form_elements' not found in wp-content/plugins/kickpress/elements/class-date.php:3
    • > PHP Fatal error
      Uncaught Error: Class 'kickpress_form_elements' not found in wp-content/plugins/kickpress/elements/class-post-types.php:3
    • > PHP Fatal error
      Uncaught Error: Class 'kickpress_form_elements' not found in wp-content/plugins/kickpress/elements/class-list.php:3
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_action() in wp-content/plugins/kickpress/kickpress-application.php:3
    • > PHP Fatal error
      Uncaught Error: Class 'kickpress_api_handler' not found in wp-content/plugins/kickpress/handlers/class-people.php:3

User-side errors Passed 1 test

🔹 Test weight: 20 | A shallow check that no browser errors were triggered
There were no browser issues found

Optimizations

Plugin configuration 90% from 29 tests

readme.txt 81% from 16 tests

You should put a lot of thought into formatting readme.txt as it is used by WordPress.org to prepare the public listing of your plugin
Attributes that need to be fixed:
  • Plugin Name: Write the name of your plugin instead of "Plugin Name" on the first line ( === kickpress === )
  • Tags: There are too many tags (11 tag instead of maximum 10)
  • Screenshots: Screenshot #1 (Adding new Post Types through the WordPress admin interface.) image missing
The official readme.txt is a good inspiration

kickpress/kickpress.php Passed 13 tests

This is the main PHP file of "KickPress" version 0.3.5, providing information about the plugin in the header fields and serving as the principal entry point to the plugin's functions
80 characters long description:
Allows for apps, themes, and APIs to be built using WordPress as a php framework

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
Success! There were no dangerous files found in this plugin23,664 lines of code in 121 files:
LanguageFilesBlank linesComment linesLines of code
PHP934,1091,70017,292
PO File172,4394,4975,281
JavaScript516254681
XML200330
CSS48580

PHP code Passed 2 tests

A brief analysis of cyclomatic complexity and code structure for this plugin
All good! No complexity issues found
Cyclomatic complexity
Average complexity per logical line of code0.44
Average class complexity18.32
▷ Minimum class complexity1.00
▷ Maximum class complexity672.00
Average method complexity3.81
▷ Minimum method complexity1.00
▷ Maximum method complexity63.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes76
▷ Abstract classes11.32%
▷ Concrete classes7598.68%
▷ Final classes00.00%
Methods470
▷ Static methods245.11%
▷ Public methods41588.30%
▷ Protected methods102.13%
▷ Private methods459.57%
Functions257
▷ Named functions25599.22%
▷ Anonymous functions20.78%
Constants19
▷ Global constants19100.00%
▷ Class constants00.00%
▷ Public constants00.00%

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
50 compressed PNG files occupy 0.04MB
Potential savings
Compression of 5 random PNG files using pngquant
FileSize - originalSize - compressedSavings
includes/images/icons/bullet_arrow_bottom.png0.22KB0.28KB0.00%
includes/images/icons/calendar_view_week.png0.47KB0.57KB0.00%
includes/images/icons/page_white_excel.png0.65KB0.63KB▼ 2.41%
includes/images/icons/delete.png0.70KB0.72KB0.00%
includes/images/toolbar_bg_over.png0.20KB0.32KB0.00%