10% system-ticket-support

Code Review | System Ticket Support

WordPress plugin System Ticket Support scored10%from 54 tests.

About plugin

  • Plugin page: system-ticket-sup...
  • Plugin version: 1.0.0
  • PHP version: 7.4.16
  • WordPress compatibility: 4.5-5.3
  • WordPress version: 6.3.1
  • First release: Mar 25, 2020
  • Latest release: Mar 28, 2020
  • Number of updates: 10
  • Update frequency: every 0.4 days
  • Top authors: g5theme (100%)

Code review

54 tests

User reviews

2 reviews

Install metrics

10+ active /902 total downloads

Benchmarks

Plugin footprint 23% from 16 tests

Installer 0% from 1 test

🔺 Critical test (weight: 50) | Verifying that this plugin installs correctly without errors
Please fix the following installer errors
  • The plugin did not install without errors
    • > Deprecated in wp-content/plugins/system-ticket-support/inc/functions/helper.php+170
    Array and string offset access syntax with curly braces is deprecated

Server metrics [RAM: ▼1.81MB] [CPU: ▼52.91ms] Passed 4 tests

Server-side resources used by System Ticket Support
This plugin has minimal impact on server resources
PageMemory (MB)CPU Time (ms)
Home /2.18 ▼1.284.44 ▼35.09
Dashboard /wp-admin2.20 ▼1.105.88 ▼38.85
Posts /wp-admin/edit.php2.20 ▼1.166.87 ▼43.90
Add New Post /wp-admin/post-new.php2.20 ▼3.695.76 ▼93.79
Media Library /wp-admin/upload.php2.20 ▼1.035.61 ▼28.68

Server storage [IO: ▲7.54MB] [DB: ▲0.03MB] Passed 3 tests

Input-output and database impact of this plugin
No storage issues were detected
Filesystem: 584 new files
Database: 13 new tables, 8 new options
New tables
wp_sts_template_tags
wp_sts_notification
wp_sts_key_mail_rate
wp_sts_user_notification
wp_sts_note
wp_sts_user_attachment
wp_sts_theme
wp_sts_message
wp_sts_mail_template
wp_sts_attachment
...
New WordPress options
widget_theysaidso_widget
theysaidso_admin_options
can_compress_scripts
widget_recent-posts
widget_recent-comments
sts_version
db_upgraded
sts_support_page_id

Browser metrics Passed 4 tests

System Ticket Support: an overview of browser usage
There were no issues detected in relation to browser resource usage
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,816 ▲8113.23 ▼0.961.66 ▼0.4841.32 ▼6.64
Dashboard /wp-admin2,222 ▲374.81 ▼1.08109.66 ▲9.5138.79 ▼1.56
Posts /wp-admin/edit.php2,102 ▲131.97 ▼0.0339.84 ▼1.2935.66 ▲0.06
Add New Post /wp-admin/post-new.php1,546 ▲923.01 ▼0.11645.28 ▲4.2451.70 ▲6.92
Media Library /wp-admin/upload.php1,404 ▲164.16 ▼0.13109.80 ▲12.0946.57 ▲5.20

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

🔸 Tests weight: 35 | It is important to correctly uninstall your plugin, without leaving any traces
The following items require your attention
  • The plugin did not uninstall gracefully
    • > Deprecated in wp-content/plugins/system-ticket-support/inc/functions/helper.php+170
    Array and string offset access syntax with curly braces is deprecated
  • Zombie tables detected upon uninstall: 13 tables
    • wp_sts_user_attachment
    • wp_sts_message
    • wp_sts_mail_template
    • wp_sts_note
    • wp_sts_user_follow_ticket
    • wp_sts_template_tags
    • wp_sts_notification
    • wp_sts_template
    • wp_sts_theme
    • wp_sts_ticket
    • ...
  • Zombie WordPress options were found after uninstall: 8 options
    • sts_version
    • sts_support_page_id
    • widget_recent-comments
    • widget_theysaidso_widget
    • can_compress_scripts
    • widget_recent-posts
    • theysaidso_admin_options
    • db_upgraded

Smoke tests 50% from 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | A smoke test targeting server-side errors
Good news, no errors were detected

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 fix the following items
  • 3× GET requests to PHP files return non-empty strings:
    • > /wp-content/plugins/system-ticket-support/templates/category/status-valid.php
    • > /wp-content/plugins/system-ticket-support/templates/login.php
    • > /wp-content/plugins/system-ticket-support/templates/ticket-details/message-item.php
  • 111× PHP files trigger server errors when accessed directly (only 10 are shown):
    • > PHP Warning
      count(): Parameter must be an array or an object that implements Countable in wp-content/plugins/system-ticket-support/templates/category/category-item.php on line 1
    • > PHP Warning
      Invalid argument supplied for foreach() in wp-content/plugins/system-ticket-support/templates/template/template-item.php on line 1
    • > PHP Fatal error
      Uncaught Error: Call to undefined function esc_url() in wp-content/plugins/system-ticket-support/templates/ticket-details/ticket-avatar.php:1
    • > PHP Notice
      Undefined variable: customers in wp-content/plugins/system-ticket-support/templates/customers/customer-item.php on line 2
    • > PHP Warning
      Invalid argument supplied for foreach() in wp-content/plugins/system-ticket-support/templates/reports/message-item.php on line 1
    • > PHP Fatal error
      Uncaught Error: Call to undefined function esc_html_e() in wp-content/plugins/system-ticket-support/templates/supporters/supporter-details.php:3
    • > PHP Fatal error
      Uncaught Error: Call to undefined function wpautop() in wp-content/plugins/system-ticket-support/templates/ticket-details/message-content.php:2
    • > PHP Warning
      Invalid argument supplied for foreach() in wp-content/plugins/system-ticket-support/templates/dashboards/ticket-item.php on line 2
    • > PHP Fatal error
      Uncaught Error: Call to undefined function esc_attr() in wp-content/plugins/system-ticket-support/templates/ticket-details/mark-process.php:4
    • > PHP Fatal error
      Uncaught Error: Call to undefined function esc_attr() in wp-content/plugins/system-ticket-support/templates/ticket-details/mark-follow.php:4

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)
No browser errors were detected

Optimizations

Plugin configuration 93% from 29 tests

readme.txt 94% from 16 tests

It's important to format your readme.txt file correctly as it is parsed for the public listing of your plugin
These attributes need your attention:
  • Plugin Name: Please specify the plugin name on the first line ( === system-ticket-support === )
You can look at the official readme.txt

system-ticket-support/system-ticket-support.php 92% from 13 tests

"System Ticket Support" version 1.0.0's primary PHP file adds more information about the plugin and serves as the entry point for WordPress
The following require your attention:
  • 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

Code Analysis 97% from 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
Good job! No executable or dangerous file extensions detected73,228 lines of code in 551 files:
LanguageFilesBlank linesComment linesLines of code
JavaScript3176,7905,11540,691
CSS371,55728614,660
PHP17281192413,315
Sass2381584,556
Markdown2106

PHP code 50% from 2 tests

This plugin's cyclomatic complexity and code structure detailed below
It is recommended to fix the following
  • Cyclomatic complexity of methods should be reduced to less than 100 (currently 101)
Cyclomatic complexity
Average complexity per logical line of code0.46
Average class complexity18.30
▷ Minimum class complexity2.00
▷ Maximum class complexity107.00
Average method complexity2.49
▷ Minimum method complexity1.00
▷ Maximum method complexity101.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes23
▷ Abstract classes00.00%
▷ Concrete classes23100.00%
▷ Final classes00.00%
Methods267
▷ Static methods238.61%
▷ Public methods267100.00%
▷ Protected methods00.00%
▷ Private methods00.00%
Functions36
▷ Named functions36100.00%
▷ Anonymous functions00.00%
Constants1
▷ Global constants1100.00%
▷ Class constants00.00%
▷ Public constants00.00%

Plugin size Passed 2 tests

Image compression Passed 2 tests

All PNG images should be compressed to minimize bandwidth usage for end users
12 PNG files occupy 0.07MB with 0.02MB in potential savings
Potential savings
Compression of 5 random PNG files using pngquant
FileSize - originalSize - compressedSavings
assets/images/youtube.png5.22KB2.88KB▼ 44.83%
assets/images/facebook.png5.54KB3.06KB▼ 44.64%
assets/vendors/jquery-ui/images/ui-icons_cc0000_256x240.png4.44KB4.17KB▼ 6.02%
assets/vendors/jquery-ui/images/ui-icons_444444_256x240.png6.83KB4.17KB▼ 38.86%
assets/vendors/jquery-ui/images/ui-icons_777620_256x240.png4.44KB4.17KB▼ 6.02%