90% button-chat-zalo-report-sw

Code Review | Contact Zalo Report SW

WordPress plugin Contact Zalo Report SW scored 90% from 54 tests.

About plugin

  • Plugin page: button-chat-zalo-...
  • Plugin version: 1.0.0
  • PHP compatiblity: 5.6+
  • PHP version: 7.4.16
  • WordPress compatibility: 5.5-6.1.1
  • WordPress version: 6.3.1
  • First release: Dec 31, 2022
  • Latest release: Dec 31, 2022
  • Number of updates: 4
  • Update frequency: every 0.3 days
  • Top authors: sonweb (100%)

Code review

54 tests

User reviews

1 review

Install metrics

100+ active / 619 total downloads

Benchmarks

Plugin footprint 83% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | Verifying that this plugin installs correctly without errors
Installer ran successfully

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

This is a short check of server-side resources used by Contact Zalo Report SW
This plugin has minimal impact on server resources
PageMemory (MB)CPU Time (ms)
Home /3.48 ▲0.0239.96 ▼1.28
Dashboard /wp-admin3.32 ▲0.0144.06 ▼4.92
Posts /wp-admin/edit.php3.37 ▲0.0143.30 ▼2.57
Add New Post /wp-admin/post-new.php5.92 ▲0.0384.04 ▼10.88
Media Library /wp-admin/upload.php3.24 ▲0.0133.68 ▲0.72
Chat Zalo Report SW /wp-admin/options-general.php?page=phone-call-zalo3.2432.04

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

Analyzing filesystem and database footprints of this plugin
There were no storage issued detected upon installing this plugin
Filesystem: 20 new files
Database: 1 new table, 6 new options
New tables
wp_chatzalosw
New WordPress options
theysaidso_admin_options
db_upgraded
can_compress_scripts
widget_recent-comments
widget_recent-posts
widget_theysaidso_widget

Browser metrics Passed 4 tests

Contact Zalo Report SW: an overview of browser usage
There were no issues detected in relation to browser resource usage
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,975 ▲21813.80 ▼0.566.38 ▲4.5645.09 ▲4.23
Dashboard /wp-admin2,234 ▲465.08 ▼0.8299.12 ▼4.1038.79 ▼5.91
Posts /wp-admin/edit.php2,116 ▲242.33 ▲0.3036.86 ▲2.4434.66 ▲3.82
Add New Post /wp-admin/post-new.php1,533 ▲1917.61 ▲0.10670.18 ▼14.5737.37 ▼22.98
Media Library /wp-admin/upload.php1,413 ▲224.41 ▲0.1796.36 ▼5.0840.61 ▼4.55
Chat Zalo Report SW /wp-admin/options-general.php?page=phone-call-zalo9792.5839.2942.68

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
It is recommended to fix the following
  • Zombie WordPress options detected upon uninstall: 6 options
    • db_upgraded
    • can_compress_scripts
    • widget_recent-comments
    • widget_theysaidso_widget
    • widget_recent-posts
    • theysaidso_admin_options

Smoke tests Passed 4 tests

Server-side errors Passed 1 test

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

SRP Passed 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
The SRP test was a success

User-side errors Passed 1 test

🔹 Test weight: 20 | A shallow check that no browser errors were triggered
Everything seems fine, but this is not an exhaustive test

Optimizations

Plugin configuration 96% from 29 tests

readme.txt Passed 16 tests

Perhaps the most important file in your plugin readme.txt gets parsed in order to generate the public listing of your plugin
4 plugin tags: call zalo, button zalo, chat zalo, report

button-chat-zalo-report-sw/zalo-chat-sw.php 92% from 13 tests

The main PHP file in "Contact Zalo Report SW" ver. 1.0.0 adds more information about the plugin and also serves as the entry point for this plugin
Please take the time to fix the following:
  • Main file name: It is recommended to name the main PHP file as the plugin slug ("button-chat-zalo-report-sw.php" instead of "zalo-chat-sw.php")

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
No dangerous file extensions were detected531 lines of code in 14 files:
LanguageFilesBlank linesComment linesLines of code
PHP104932295
CSS210218
JavaScript24218

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.19
Average class complexity1.00
▷ Minimum class complexity1.00
▷ Maximum class complexity1.00
Average method complexity1.00
▷ Minimum method complexity1.00
▷ Maximum method complexity1.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes1
▷ Abstract classes00.00%
▷ Concrete classes1100.00%
▷ Final classes00.00%
Methods2
▷ Static methods00.00%
▷ Public methods2100.00%
▷ Protected methods00.00%
▷ Private methods00.00%
Functions9
▷ Named functions9100.00%
▷ Anonymous functions00.00%
Constants2
▷ Global constants2100.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
2 compressed PNG files occupy 0.00MB
Potential savings
Compression of 2 random PNG files using pngquant
FileSize - originalSize - compressedSavings
assets/zalo-icon.png1.80KB1.83KB0.00%
assets/phone-ring.png0.36KB0.37KB0.00%