84% goqsmile

Code Review | GoQSmile

WordPress plugin GoQSmile scored84%from 54 tests.

About plugin

  • Plugin page: goqsmile
  • Plugin version: 1.0.1
  • PHP version: 7.4.16
  • WordPress compatibility: 3.1.1-4.9.8
  • WordPress version: 6.3.1
  • First release: Aug 15, 2018
  • Latest release: Aug 19, 2019
  • Number of updates: 14
  • Update frequency: every 26.5 days
  • Top authors: goqsystem (100%)

Code review

54 tests

User reviews

1 review

Install metrics

10+ active /902 total downloads

Benchmarks

Plugin footprint 83% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | Checking the installer triggered no errors
Installer ran successfully

Server metrics [RAM: ▼0.11MB] [CPU: ▼20.26ms] Passed 4 tests

Server-side resources used by GoQSmile
This plugin does not affect your website's performance
PageMemory (MB)CPU Time (ms)
Home /3.50 ▲0.0333.96 ▼2.86
Dashboard /wp-admin3.27 ▼0.0830.44 ▼30.64
Posts /wp-admin/edit.php3.33 ▼0.0335.58 ▼14.66
Add New Post /wp-admin/post-new.php5.52 ▼0.3771.12 ▼31.33
Media Library /wp-admin/upload.php3.27 ▲0.0428.17 ▼4.41

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

Analyzing filesystem and database footprints of this plugin
No storage issues were detected
Filesystem: 17 new files
Database: no new tables, 7 new options
New WordPress options
widget_recent-comments
gqs_system_setting
db_upgraded
can_compress_scripts
widget_recent-posts
widget_theysaidso_widget
theysaidso_admin_options

Browser metrics Passed 4 tests

A check of browser resources used by GoQSmile
There were no issues detected in relation to browser resource usage
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,811 ▲5413.20 ▼1.554.27 ▲2.2539.79 ▼1.07
Dashboard /wp-admin2,214 ▲264.93 ▲0.01106.10 ▲2.4267.25 ▲21.37
Posts /wp-admin/edit.php2,097 ▲82.02 ▼0.0038.07 ▼3.8234.66 ▼2.85
Add New Post /wp-admin/post-new.php1,529 ▼1323.12 ▲4.64726.31 ▲101.7958.98 ▼4.97
Media Library /wp-admin/upload.php1,399 ▲174.18 ▼0.08102.44 ▲5.6549.00 ▲5.53

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

🔸 Tests weight: 35 | It is important to correctly uninstall your plugin, without leaving any traces
Please fix the following items
  • Zombie WordPress options detected upon uninstall: 7 options
    • gqs_system_setting
    • theysaidso_admin_options
    • widget_recent-comments
    • can_compress_scripts
    • widget_theysaidso_widget
    • widget_recent-posts
    • db_upgraded

Smoke tests 75% 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 50% from 2 tests

🔹 Tests weight: 20 | The single-responsibility principle: PHP files have to remain inert when accessed directly, throwing no errors and performing no actions
The following issues need your attention
  • 4× PHP files trigger server errors when accessed directly:
    • > PHP Fatal error
      Uncaught Error: Class 'GOQSMILE_Admin_Page' not found in wp-content/plugins/goqsmile/admin/class-admin-setting.php:2
    • > PHP Warning
      Use of undefined constant WP_PLUGIN_DIR - assumed 'WP_PLUGIN_DIR' (this will throw an Error in a future version of PHP) in wp-content/plugins/goqsmile/goqsmile.php on line 14
    • > PHP Fatal error
      Uncaught Error: Call to undefined function current_user_can() in wp-content/plugins/goqsmile/admin/views/system-setting.php:2
    • > PHP Fatal error
      Uncaught Error: Call to undefined function plugin_basename() in wp-content/plugins/goqsmile/goqsmile.php:14

User-side errors Passed 1 test

🔹 Test weight: 20 | This is a smoke test targeting browser errors/issues
There were no browser issues found

Optimizations

Plugin configuration Passed 29 tests

readme.txt Passed 16 tests

The readme.txt file is undoubtedly the most important file in your plugin, preparing it for public listing on WordPress.org
3 plugin tags: goqsmile, chatbot, chat

goqsmile/goqsmile.php Passed 13 tests

The main PHP script in "GoQSmile" version 1.0.1 is automatically included on every request by WordPress
86 characters long description:
すぐに使える直感的チャットボット。GoQSmile(ごくースマイル)

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 plugin608 lines of code in 10 files:
LanguageFilesBlank linesComment linesLines of code
PHP8134184492
CSS230116

PHP code Passed 2 tests

A short review of cyclomatic complexity and code structure
Great job! No cyclomatic complexity issues were detected in this plugin
Cyclomatic complexity
Average complexity per logical line of code0.26
Average class complexity11.00
▷ Minimum class complexity2.00
▷ Maximum class complexity30.00
Average method complexity2.06
▷ Minimum method complexity1.00
▷ Maximum method complexity16.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes5
▷ Abstract classes00.00%
▷ Concrete classes5100.00%
▷ Final classes00.00%
Methods47
▷ Static methods1021.28%
▷ Public methods4085.11%
▷ Protected methods12.13%
▷ Private methods612.77%
Functions0
▷ Named functions00.00%
▷ Anonymous functions00.00%
Constants6
▷ Global constants6100.00%
▷ Class constants00.00%
▷ Public constants00.00%

Plugin size Passed 2 tests

Image compression Passed 2 tests

Often times overlooked, PNG files can occupy unnecessary space in your plugin
4 PNG files occupy 0.11MB with 0.07MB in potential savings
Potential savings
Compression of 4 random PNG files using pngquant
FileSize - originalSize - compressedSavings
admin/assets/images/icon-goqsmile.png2.10KB0.58KB▼ 72.49%
admin/assets/images/img_complete.png64.76KB32.25KB▼ 50.21%
admin/assets/images/logo.png3.66KB1.88KB▼ 48.54%
admin/assets/images/img_capture_01.png46.41KB16.90KB▼ 63.58%