84% eyoung

Code Review | Eyoung Service Online System - Eyoung在线客服系统

WordPress plugin Eyoung Service Online System - Eyoung在线客服系统 scored84%from 54 tests.

About plugin

  • Plugin page: eyoung
  • Plugin version: 1.0
  • PHP version: 7.4.16
  • WordPress compatibility: 4.8-5.9
  • WordPress version: 6.3.1
  • First release: Feb 26, 2022
  • Latest release: Jul 10, 2023
  • Number of updates: 33
  • Update frequency: every 15.2 days
  • Top authors: yuyaoit (100%)

Code review

54 tests

User reviews

1 review

Install metrics

20+ active /2,331 total downloads

Benchmarks

Plugin footprint 83% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | The install procedure must perform silently
Installer ran successfully

Server metrics [RAM: ▲0.31MB] [CPU: ▼8.37ms] Passed 4 tests

Analyzing server-side resources used by Eyoung Service Online System - Eyoung在线客服系统
This plugin does not affect your website's performance
PageMemory (MB)CPU Time (ms)
Home /3.77 ▲0.3145.52 ▲1.14
Dashboard /wp-admin3.63 ▲0.2854.79 ▼16.53
Posts /wp-admin/edit.php3.74 ▲0.3855.12 ▼0.66
Add New Post /wp-admin/post-new.php6.23 ▲0.3494.51 ▼17.43
Media Library /wp-admin/upload.php3.55 ▲0.3241.39 ▲1.87
客服中心 /wp-admin/admin.php?page=ey_serviceonline-gocenter3.5237.52
客户管理 /wp-admin/admin.php?page=ey_serviceonline-customer3.5338.33
沟通记录 /wp-admin/admin.php?page=ey_serviceonline-chat3.5334.80
客服设置 /wp-admin/admin.php?page=ey_serviceonline-setsever3.5335.99
参数设置 /wp-admin/admin.php?page=ey_serviceonline-setting3.5833.80

Server storage [IO: ▲1.35MB] [DB: ▲0.01MB] Passed 3 tests

Filesystem and database footprint
This plugin was installed successfully
Filesystem: 148 new files
Database: 7 new tables, 7 new options
New tables
wp_ey_serviceonline_attach
wp_ey_serviceonline_customer
wp_ey_serviceonline_maillog
wp_ey_serviceonline_setting
wp_ey_serviceonline_editlog
wp_ey_serviceonline_content
wp_ey_serviceonline_track
New WordPress options
eyser_options
can_compress_scripts
theysaidso_admin_options
widget_theysaidso_widget
widget_recent-posts
widget_recent-comments
db_upgraded

Browser metrics Passed 4 tests

Eyoung Service Online System - Eyoung在线客服系统: an overview of browser usage
This plugin renders optimally with no browser resource issues detected
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /3,083 ▲32214.35 ▼0.369.50 ▲7.6844.26 ▲2.73
Dashboard /wp-admin2,338 ▲1615.77 ▲0.1091.39 ▲0.2145.41 ▲3.70
Posts /wp-admin/edit.php2,253 ▲1532.72 ▲0.7045.17 ▲9.5140.28 ▲4.11
Add New Post /wp-admin/post-new.php1,823 ▲28723.72 ▲5.64705.37 ▲84.0842.76 ▼37.46
Media Library /wp-admin/upload.php1,555 ▲1525.15 ▲0.92109.48 ▲4.4151.73 ▲5.34
客服中心 /wp-admin/admin.php?page=ey_serviceonline-gocenter1,4763.0532.5766.46
客户管理 /wp-admin/admin.php?page=ey_serviceonline-customer1,0962.8347.1875.63
沟通记录 /wp-admin/admin.php?page=ey_serviceonline-chat1,0592.7048.3552.71
客服设置 /wp-admin/admin.php?page=ey_serviceonline-setsever1,1722.3740.3449.01
参数设置 /wp-admin/admin.php?page=ey_serviceonline-setting1,6822.5741.6052.07

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
  • This plugin did not uninstall successfully, leaving 6 options in the database
    • widget_recent-comments
    • can_compress_scripts
    • widget_recent-posts
    • db_upgraded
    • theysaidso_admin_options
    • widget_theysaidso_widget

Smoke tests 75% from 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | A shallow check that no server-side errors were triggered
Good news, no errors were detected

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
Please take a closer look at the following
  • 7× PHP files trigger server errors when accessed directly:
    • > PHP Fatal error
      Uncaught Error: Call to undefined function get_header() in wp-content/plugins/eyoung/assets/servicecenter.php:1
    • > PHP Fatal error
      Uncaught Error: Call to undefined function _e() in wp-content/plugins/eyoung/assets/setting.php:17
    • > PHP Fatal error
      Uncaught Error: Call to undefined function _e() in wp-content/plugins/eyoung/assets/scripth5.php:8
    • > PHP Fatal error
      Uncaught Error: Call to undefined function _e() in wp-content/plugins/eyoung/assets/customer.php:10
    • > PHP Fatal error
      Uncaught Error: Call to undefined function _e() in wp-content/plugins/eyoung/assets/chat.php:10
    • > PHP Fatal error
      Uncaught Error: Call to undefined function _e() in wp-content/plugins/eyoung/assets/sever.php:21
    • > PHP Fatal error
      Uncaught Error: Call to undefined function _e() in wp-content/plugins/eyoung/assets/scriptpc.php:8

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 96% from 29 tests

readme.txt Passed 16 tests

Often overlooked, readme.txt is one of the most important files in your plugin
8 plugin tags: contact, chat, email, qq, webim...

eyoung/index.php 92% from 13 tests

The main PHP script in "Eyoung Service Online System - Eyoung在线客服系统" version 1.0 is automatically included on every request by WordPress
Please make the necessary changes and fix the following:
  • Main file name: Please rename the main PHP file in this plugin to the plugin slug ("eyoung.php" instead of "index.php")

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 detected2,896 lines of code in 29 files:
LanguageFilesBlank linesComment linesLines of code
PHP18230742,687
SVG13563195
JavaScript4008
CSS6006

PHP code Passed 2 tests

A brief analysis 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.31
Average class complexity25.44
▷ Minimum class complexity3.00
▷ Maximum class complexity102.00
Average method complexity3.27
▷ Minimum method complexity1.00
▷ Maximum method complexity28.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes9
▷ Abstract classes00.00%
▷ Concrete classes9100.00%
▷ Final classes00.00%
Methods92
▷ Static methods8996.74%
▷ Public methods7076.09%
▷ Protected methods00.00%
▷ Private methods2223.91%
Functions3
▷ Named functions00.00%
▷ Anonymous functions3100.00%
Constants4
▷ Global constants4100.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
4 PNG files occupy 0.03MB with 0.01MB in potential savings
Potential savings
Compression of 4 random PNG files using pngquant
FileSize - originalSize - compressedSavings
dist/css/modules/layer/default/icon-ext.png5.77KB2.91KB▼ 49.62%
images/ver.png1.70KB1.58KB▼ 7.16%
images/ser.png8.01KB2.51KB▼ 68.63%
dist/css/modules/layer/default/icon.png11.22KB4.36KB▼ 61.19%