72% ace-social-chat

Code Review | Ace Social Chat

WordPress plugin Ace Social Chat scored72%from 54 tests.

About plugin

  • Plugin page: ace-social-chat
  • Plugin version: 1.0.4
  • PHP compatiblity: 5.6.0+
  • PHP version: 7.4.16
  • WordPress compatibility: 4.9-6.0
  • WordPress version: 6.3.1
  • First release: Mar 23, 2021
  • Latest release: Jul 4, 2022
  • Number of updates: 25
  • Update frequency: every 36.2 days
  • Top authors: acewebx (100%)

Code review

54 tests

User reviews

1 review

Install metrics

10+ active /734 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
Install script ran successfully

Server metrics [RAM: ▲0.05MB] [CPU: ▼0.94ms] Passed 4 tests

Analyzing server-side resources used by Ace Social Chat
Normal server usage
PageMemory (MB)CPU Time (ms)
Home /3.57 ▲0.1138.48 ▼4.91
Dashboard /wp-admin3.34 ▲0.0446.75 ▲0.24
Posts /wp-admin/edit.php3.39 ▲0.0447.32 ▼2.77
Add New Post /wp-admin/post-new.php5.95 ▲0.0699.33 ▲3.69
Media Library /wp-admin/upload.php3.27 ▲0.0434.22 ▲3.86
Add Agent /wp-admin/post-new.php?post_type=ace_whatsapp_agent3.3747.51
Setting /wp-admin/edit.php?post_type=ace_whatsapp_agent&page=ace_whatsapp_style3.3136.38
All Agents /wp-admin/edit.php?post_type=ace_whatsapp_agent3.3136.53

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

How much does this plugin use your filesystem and database?
No storage issues were detected
Filesystem: 27 new files
Database: no new tables, 9 new options
New WordPress options
awm_users_sortable_
can_compress_scripts
theysaidso_admin_options
widget_recent-posts
widget_recent-comments
ace-whatsapp-setting-field-M
widget_theysaidso_widget
ace-social-default-status
db_upgraded

Browser metrics Passed 4 tests

An overview of browser requirements for Ace Social Chat
This plugin renders optimally with no browser resource issues detected
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,965 ▲23013.70 ▼0.664.93 ▲3.2491.84 ▲44.78
Dashboard /wp-admin2,247 ▲614.90 ▼0.03110.28 ▲0.6443.79 ▲1.82
Posts /wp-admin/edit.php2,134 ▲452.23 ▲0.2340.91 ▼0.7235.06 ▼1.75
Add New Post /wp-admin/post-new.php1,559 ▲3118.20 ▲0.00610.75 ▼16.6759.87 ▲9.61
Media Library /wp-admin/upload.php1,426 ▲354.21 ▲0.0198.70 ▼0.7641.58 ▼2.11
Add Agent /wp-admin/post-new.php?post_type=ace_whatsapp_agent3,8263.7674.2140.13
Setting /wp-admin/edit.php?post_type=ace_whatsapp_agent&page=ace_whatsapp_style1,0672.0935.3045.24
All Agents /wp-admin/edit.php?post_type=ace_whatsapp_agent1,1132.1935.4030.10

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
These items require your attention
  • This plugin did not uninstall successfully, leaving 9 options in the database
    • ace-whatsapp-setting-field-M
    • theysaidso_admin_options
    • db_upgraded
    • widget_recent-posts
    • can_compress_scripts
    • widget_recent-comments
    • awm_users_sortable_
    • widget_theysaidso_widget
    • ace-social-default-status

Smoke tests 25% from 4 tests

Server-side errors 0% from 1 test

🔹 Test weight: 20 | This is a short smoke test looking for server-side errors
These errors were triggered by the plugin
    • > GET request to /wp-admin/edit.php?post_type=ace_whatsapp_agent&page=ace_whatsapp_style
    • > Notice in wp-content/plugins/ace-social-chat/admin/partials/ace-social-chat-admin-settings.php+61
    Undefined variable: ace_whatsapp_txtbtn_color

SRP 50% 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
Please fix the following
  • 5× PHP files trigger errors when accessed directly with GET requests:
    • > PHP Fatal error
      Uncaught Error: Call to undefined function get_post_meta() in wp-content/plugins/ace-social-chat/admin/partials/ace-social-chat-admin-display.php:17
    • > PHP Fatal error
      Uncaught Error: Call to undefined function get_option() in wp-content/plugins/ace-social-chat/public/partials/ace-social-chat-public-widget.php:4
    • > PHP Fatal error
      Uncaught Error: Call to undefined function _e() in wp-content/plugins/ace-social-chat/admin/partials/ace-social-chat-admin-settings.php:10
    • > PHP Fatal error
      Uncaught Error: Call to undefined function get_option() in wp-content/plugins/ace-social-chat/public/partials/ace-social-chat-public-display.php:16
    • > PHP Notice
      Trying to get property 'ID' of non-object in wp-content/plugins/ace-social-chat/admin/partials/ace-social-chat-admin-display.php on line 16

User-side errors 0% from 1 test

🔹 Test weight: 20 | Just a short smoke test targeting errors on the browser (console and network errors and warnings)
Please take a look at the following user-side issues
    • > GET request to /wp-admin/edit.php?post_type=ace_whatsapp_agent&page=ace_whatsapp_style
    • > Rendering (warning) in unknown
    /wp-admin/edit.php?post_type=ace_whatsapp_agent&page=ace_whatsapp_style 187 The specified value "" does not conform to the required format. The format is "#rrggbb" where rr, gg, bb are two-digit hexadecimal numbers.
    • > GET request to /wp-admin/edit.php?post_type=ace_whatsapp_agent&page=ace_whatsapp_style
    • > Rendering (warning) in unknown
    /wp-admin/edit.php?post_type=ace_whatsapp_agent&page=ace_whatsapp_style 198 The specified value "" does not conform to the required format. The format is "#rrggbb" where rr, gg, bb are two-digit hexadecimal numbers.
    • > GET request to /wp-admin/edit.php?post_type=ace_whatsapp_agent&page=ace_whatsapp_style
    • > Javascript (severe) in unknown
    /wp-admin/edit.php?post_type=ace_whatsapp_agent&page=ace_whatsapp_style - Access to XMLHttpRequest at 'https://www.paypal.me/acewebx' from origin '' has been blocked by CORS policy: No 'Access-Control-Allow-Origin' header is present on the requested resource.
    • > GET request to /wp-admin/edit.php?post_type=ace_whatsapp_agent&page=ace_whatsapp_style
    • > Network (severe)
    https://www.paypal.me/acewebx - Failed to load resource: net::ERR_FAILED

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:
  • Screenshots: These screenshots require images: #1 (**Installation** - Search Ace Social Chat & Install Ace Social Chat Plugin.), #2 (**Activation** - Activate Ace Social Chat Plugin.), #3 (**Whatsapp Chat Menu** - Check Your Dashboard And here's your Whatsapp chat menu By Plugin.), #4 (**Add Agents** - Add Multiple Agents For your Website through Whatsapp Chat menu.), #5 (**Added Details** - Add All Details of Agents whose Whatsapp contact to be Shared for whatsapp chat.), #6 (**Settings** - Make Customization in settings according your requirements. Button Color, Background color, text colour, Display options, Woocommerce.), #7 (**Whatsapp on Page** - On your page whatsapp icon display, click on icon and see agent name and details with message.), #8 (**Whatsapp Web** - Login with Whatsapp and start Conversation.), #9 (**Shortcodes** - Also get shoctcodes of added Agents, that can applied in multiple section according to the requirements.)
The official readme.txt might help

ace-social-chat/ace-social-chat.php 92% from 13 tests

This is the main PHP file of "Ace Social Chat" version 1.0.4, providing information about the plugin in the header fields and serving as the principal entry point to the plugin's functions
It is important to fix the following:
  • Description: If Twitter did it, so should we! Keep the description under 140 characters (currently 166 characters long)

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | This is an overview of programming languages used in this plugin; dangerous file extensions are not allowed
Everything looks great! No dangerous files found in this plugin2,008 lines of code in 19 files:
LanguageFilesBlank linesComment linesLines of code
CSS3120371,107
PHP14193537893
JavaScript24548

PHP code Passed 2 tests

This is a very shot review of cyclomatic complexity and code structure
No complexity issues detected
Cyclomatic complexity
Average complexity per logical line of code0.32
Average class complexity9.29
▷ Minimum class complexity1.00
▷ Maximum class complexity48.00
Average method complexity2.66
▷ Minimum method complexity1.00
▷ Maximum method complexity25.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes7
▷ Abstract classes00.00%
▷ Concrete classes7100.00%
▷ Final classes00.00%
Methods35
▷ Static methods25.71%
▷ Public methods3085.71%
▷ Protected methods00.00%
▷ Private methods514.29%
Functions3
▷ Named functions3100.00%
▷ Anonymous functions00.00%
Constants1
▷ Global constants1100.00%
▷ Class constants00.00%
▷ Public constants00.00%

Plugin size 50% from 2 tests

Image compression 50% from 2 tests

PNG files should be compressed to save space and minimize bandwidth usage
2 PNG files occupy 0.52MB with 0.26MB in potential savings
Potential savings
Compression of 2 random PNG files using pngquant
FileSize - originalSize - compressedSavings
public/images/mOnline.png2.06KB1.03KB▼ 49.93%
public/images/whatsapp-bkg.png534.52KB277.49KB▼ 48.09%