78% send-sms-in-pakistan

Code Review | SEND SMS in Pakistan

WordPress plugin SEND SMS in Pakistan scored 78% from 54 tests.

About plugin

  • Plugin page: send-sms-in-pakistan
  • Plugin version: 3.0.4
  • PHP compatiblity: 5.4+
  • PHP version: 7.4.16
  • WordPress compatibility: 5.0.7-6.1.1
  • WordPress version: 6.3.1
  • First release: Mar 17, 2023
  • Latest release: Mar 17, 2023
  • Number of updates: 4
  • Update frequency: every 0.5 days
  • Top authors: hatinc (100%)

Code review

54 tests

User reviews

1 review

Install metrics

10+ active / 226 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
This plugin's installer ran successfully

Server metrics [RAM: ▲0.09MB] [CPU: ▲3.69ms] Passed 4 tests

Analyzing server-side resources used by SEND SMS in Pakistan
Server-side resource usage in normal parameters
PageMemory (MB)CPU Time (ms)
Home /3.55 ▲0.0950.07 ▲4.11
Dashboard /wp-admin3.39 ▲0.0849.83 ▼3.72
Posts /wp-admin/edit.php3.50 ▲0.1553.40 ▲2.57
Add New Post /wp-admin/post-new.php5.99 ▲0.10113.49 ▲17.27
Media Library /wp-admin/upload.php3.31 ▲0.0846.80 ▲11.81
Send SMS /wp-admin/options-general.php?page=send_sms3.2934.52

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

A short overview of filesystem and database impact
This plugin installed successfully
Filesystem: 19 new files
Database: no new tables, 6 new options
New WordPress options
db_upgraded
can_compress_scripts
widget_theysaidso_widget
theysaidso_admin_options
widget_recent-comments
widget_recent-posts

Browser metrics Passed 4 tests

A check of browser resources used by SEND SMS in Pakistan
This plugin renders optimally with no browser resource issues detected
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,835 ▲3513.40 ▼1.002.10 ▲0.3743.66 ▼1.92
Dashboard /wp-admin2,213 ▲45.88 ▲1.04100.27 ▼11.3639.51 ▼2.94
Posts /wp-admin/edit.php2,099 ▲72.08 ▲0.0335.96 ▲1.4829.37 ▼5.81
Add New Post /wp-admin/post-new.php1,527 ▼623.29 ▲0.04638.13 ▲8.3459.69 ▲2.93
Media Library /wp-admin/upload.php1,401 ▲134.29 ▲0.0298.03 ▼5.5641.14 ▼1.31
Send SMS /wp-admin/options-general.php?page=send_sms9551.9124.6326.69

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

🔸 Tests weight: 35 | It is important to correctly uninstall your plugin, without leaving any traces
You still need to fix the following
  • The uninstall procedure has failed, leaving 6 options in the database
    • widget_theysaidso_widget
    • widget_recent-comments
    • db_upgraded
    • can_compress_scripts
    • theysaidso_admin_options
    • widget_recent-posts

Smoke tests 50% from 4 tests

Server-side errors 0% from 1 test

🔹 Test weight: 20 | This is a short smoke test looking for server-side errors
Please fix the following server-side errors
  • 5 occurences, only the last one shown
    • > GET request to /wp-admin/options-general.php?page=send_sms
    • > Notice in wp-content/plugins/send-sms-in-pakistan/includes/admin-ui.php+95
    Trying to access array offset on value of type bool

SRP 50% from 2 tests

🔹 Tests weight: 20 | SRP (Single-Responsibility Principle) - PHP files must act as libraries and never output text or perform any action when accessed directly in a browser
The following issues need your attention
  • 1× PHP files output text when accessed directly:
    • > /wp-content/plugins/send-sms-in-pakistan/includes/sms_client_widget.php

User-side errors Passed 1 test

🔹 Test weight: 20 | A shallow check that no browser errors were triggered
There were no browser issues found

Optimizations

Plugin configuration 90% from 29 tests

readme.txt 94% from 16 tests

Often overlooked, readme.txt is one of the most important files in your plugin
These attributes need your attention:
  • Tags: Too many tags (11 tag instead of maximum 10); only the first 5 tags are used in your directory listing
You can take inspiration from this readme.txt

send-sms-in-pakistan/send_sms.php 85% from 13 tests

The main PHP file in "SEND SMS in Pakistan" ver. 3.0.4 adds more information about the plugin and also serves as the entry point for this plugin
Please make the necessary changes and fix the following:
  • Main file name: It is recommended to name the main PHP file as the plugin slug ("send-sms-in-pakistan.php" instead of "send_sms.php")
  • Text Domain: The text domain name should consist of only dashes and lowercase characters

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | A short check of programming languages and file extensions; no executable files are allowed
Good job! No executable or dangerous file extensions detected791 lines of code in 13 files:
LanguageFilesBlank linesComment linesLines of code
PHP994180608
JavaScript21822116
CSS10036
Markdown113031

PHP code Passed 2 tests

An short overview of logical lines of code, cyclomatic complexity, and other code metrics
Everything seems fine, there were no complexity issues found
Cyclomatic complexity
Average complexity per logical line of code0.31
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
Namespaces1
Interfaces0
Traits0
Classes2
▷ Abstract classes00.00%
▷ Concrete classes2100.00%
▷ Final classes00.00%
Methods7
▷ Static methods00.00%
▷ Public methods571.43%
▷ Protected methods00.00%
▷ Private methods228.57%
Functions14
▷ Named functions14100.00%
▷ Anonymous functions00.00%
Constants0
▷ Global constants00.00%
▷ Class constants00.00%
▷ Public constants00.00%

Plugin size Passed 2 tests

Image compression Passed 2 tests

PNG files should be compressed to save space and minimize bandwidth usage
No PNG images were found in this plugin