79% kemet-addons

Code Review | Kemet Addons

WordPress plugin Kemet Addons scored79%from 54 tests.

About plugin

  • Plugin page: kemet-addons
  • Plugin version: 1.1.21
  • PHP compatiblity: 5.4+
  • PHP version: 7.4.16
  • WordPress compatibility: 4.7-5.7
  • WordPress version: 6.3.1
  • First release: Jul 16, 2019
  • Latest release: May 27, 2021
  • Number of updates: 37
  • Update frequency: every 18.5 days
  • Top authors: leap13 (100%)

Code review

54 tests

User reviews

1 review

Install metrics

60+ active /4,363 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
The plugin installed gracefully, with no errors

Server metrics [RAM: ▼0.01MB] [CPU: ▼9.71ms] Passed 4 tests

A check of server-side resources used by Kemet Addons
No issues were detected with server-side resource usage
PageMemory (MB)CPU Time (ms)
Home /3.46 ▲0.0033.04 ▼5.69
Dashboard /wp-admin3.31 ▼0.0444.65 ▼24.99
Posts /wp-admin/edit.php3.36 ▲0.0047.15 ▼0.82
Add New Post /wp-admin/post-new.php5.89 ▲0.0094.94 ▼7.27
Media Library /wp-admin/upload.php3.23 ▲0.0033.17 ▼0.87

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

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

Browser metrics Passed 4 tests

An overview of browser requirements for Kemet Addons
There were no issues detected in relation to browser resource usage
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,800 ▲5413.30 ▼1.071.67 ▼0.0645.13 ▼0.15
Dashboard /wp-admin2,209 ▲214.85 ▼0.0498.12 ▼19.5240.47 ▼4.24
Posts /wp-admin/edit.php2,089 ▼02.01 ▲0.0040.19 ▲1.6134.96 ▼1.95
Add New Post /wp-admin/post-new.php1,542 ▼018.22 ▲0.06609.05 ▼54.0360.23 ▼1.92
Media Library /wp-admin/upload.php1,385 ▼34.20 ▼0.0598.32 ▼13.1641.06 ▼4.59

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

🔸 Tests weight: 35 | Checking the uninstaller removed all traces of the plugin
These items require your attention
  • The uninstall procedure has failed, leaving 6 options in the database
    • widget_theysaidso_widget
    • theysaidso_admin_options
    • can_compress_scripts
    • db_upgraded
    • widget_recent-posts
    • widget_recent-comments

Smoke tests 50% from 4 tests

Server-side errors Passed 1 test

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

SRP 0% 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
  • 2× GET requests to PHP files return non-empty strings:
    • > /wp-content/plugins/kemet-addons/addons/woocommerce/templates/quick-view-model.php
    • > /wp-content/plugins/kemet-addons/addons/reset-import-export/templates/import-form.php
  • 144× PHP files trigger errors when accessed directly with GET requests (only 10 are shown):
    • > PHP Fatal error
      require_once(): Failed opening required 'KEMET_ADDONS_DIRaddons/single-post/classes/class-kemet-addon-single-post-partials.php' (include_path='.:/usr/share/php') in wp-content/plugins/kemet-addons/addons/single-post/class-kemet-addon-single-post.php on line 44
    • > PHP Fatal error
      require_once(): Failed opening required 'KEMET_ADDONS_DIRaddons/sticky-header/classes/class-kemet-addon-sticky-header-settings.php' (include_path='.:/usr/share/php') in wp-content/plugins/kemet-addons/addons/sticky-header/class-kemet-addon-sticky-header.php on line 44
    • > PHP Fatal error
      Uncaught Error: Class 'Kemet_Theme_Options' not found in wp-content/plugins/kemet-addons/addons/extra-widgets/customizer/customizer-options.php:8
    • > PHP Warning
      Use of undefined constant KEMET_ADDONS_URL - assumed 'KEMET_ADDONS_URL' (this will throw an Error in a future version of PHP) in wp-content/plugins/kemet-addons/addons/sticky-header/class-kemet-addon-sticky-header.php on line 9
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_filter() in wp-content/plugins/kemet-addons/addons/single-post/classes/dynamic.css.php:8
    • > PHP Fatal error
      Uncaught Error: Class 'Kemet_Theme_Options' not found in wp-content/plugins/kemet-addons/addons/blog-layouts/customizer/customizer-options.php:8
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_action() in wp-content/plugins/kemet-addons/addons/mega-menu/classes/class-kemet-addon-mega-menu-partials.php:52
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_action() in wp-content/plugins/kemet-addons/addons/go-top/classes/class-kemet-addon-go-top-partials.php:38
    • > PHP Warning
      Use of undefined constant KEMET_ADDONS_URL - assumed 'KEMET_ADDONS_URL' (this will throw an Error in a future version of PHP) in wp-content/plugins/kemet-addons/addons/custom-layout/class-kemet-addon-custom-layout.php on line 9
    • > PHP Warning
      Use of undefined constant KEMET_ADDONS_DIR - assumed 'KEMET_ADDONS_DIR' (this will throw an Error in a future version of PHP) in wp-content/plugins/kemet-addons/addons/reset-import-export/class-kemet-addon-reset-import-export.php on line 8

User-side errors Passed 1 test

🔹 Test weight: 20 | This is a shallow check for browser errors
Everything seems fine, but this is not an exhaustive test

Optimizations

Plugin configuration Passed 29 tests

readme.txt Passed 16 tests

Often overlooked, readme.txt is one of the most important files in your plugin
3 plugin tags: kemet, metabox, addons

kemet-addons/kemet-addons.php Passed 13 tests

The main PHP file in "Kemet Addons" ver. 1.1.21 adds more information about the plugin and also serves as the entry point for this plugin
27 characters long description:
This Plugin for Kemet Theme

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | A short glimpse at programming languages used with this plugin and a check that no dangerous files are present
No dangerous file extensions were detected58,027 lines of code in 324 files:
LanguageFilesBlank linesComment linesLines of code
CSS613,37891723,229
PHP1453,1086,60018,754
JavaScript1142,16384110,995
SVG3005,030
Markdown13019

PHP code Passed 2 tests

This is a short overview 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.40
Average class complexity21.40
▷ Minimum class complexity1.00
▷ Maximum class complexity204.00
Average method complexity4.13
▷ Minimum method complexity1.00
▷ Maximum method complexity52.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes91
▷ Abstract classes44.40%
▷ Concrete classes8795.60%
▷ Final classes11.15%
Methods589
▷ Static methods10217.32%
▷ Public methods54091.68%
▷ Protected methods488.15%
▷ Private methods10.17%
Functions44
▷ Named functions3579.55%
▷ Anonymous functions920.45%
Constants39
▷ Global constants39100.00%
▷ Class constants00.00%
▷ Public constants00.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
23 PNG files occupy 0.01MB with 0.01MB in potential savings
Potential savings
Compression of 5 random PNG files using pngquant
FileSize - originalSize - compressedSavings
addons/blog-layouts/assets/images/classic-blog.png0.51KB0.16KB▼ 69.83%
addons/extra-headers/assets/images/header-layout-04.png0.41KB0.14KB▼ 65.38%
addons/blog-layouts/assets/images/large-modern-blog.png0.49KB0.18KB▼ 63.04%
addons/extra-headers/assets/images/header-layout-05.png0.42KB0.16KB▼ 61.72%
addons/extra-headers/assets/images/header-layout-02.png0.39KB0.14KB▼ 64.66%