10% branded-sms

Code Review | Branded SMS

WordPress plugin Branded SMS scored10%from 54 tests.

About plugin

  • Plugin page: branded-sms
  • Plugin version: 4.4.3
  • PHP version: 7.4.16
  • WordPress compatibility: 3.8-5.5
  • WordPress version: 6.3.1
  • First release: Aug 30, 2017
  • Latest release: Mar 18, 2020
  • Number of updates: 25
  • Update frequency: every 37.4 days
  • Top authors: naqirizvi (100%)

Code review

54 tests

User reviews

2 reviews

Install metrics

10+ active /1,667 total downloads

Benchmarks

Plugin footprint 40% from 16 tests

Installer 0% from 1 test

🔺 Critical test (weight: 50) | The install procedure must perform silently
It is recommended to fix the following installer errors
  • Install procedure validation failed for this plugin
    • > Warning in wp-includes/functions.php+6691
    file_get_contents(wp-content/plugins/woocommerce/woocommerce.php): failed to open stream: No such file or directory

Server metrics [RAM: ▲0.00MB] [CPU: ▼6.14ms] Passed 4 tests

Server-side resources used by Branded SMS
This plugin has minimal impact on server resources
PageMemory (MB)CPU Time (ms)
Home /3.46 ▲0.0040.06 ▲0.17
Dashboard /wp-admin3.31 ▲0.0045.66 ▼6.01
Posts /wp-admin/edit.php3.36 ▲0.0048.64 ▼6.75
Add New Post /wp-admin/post-new.php5.89 ▲0.0094.36 ▼10.23
Media Library /wp-admin/upload.php3.23 ▲0.0035.70 ▼1.57

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

Input-output and database impact of this plugin
This plugin installed successfully
Filesystem: 36 new files
Database: no new tables, 6 new options
New WordPress options
widget_theysaidso_widget
widget_recent-comments
db_upgraded
widget_recent-posts
can_compress_scripts
theysaidso_admin_options

Browser metrics Passed 4 tests

Branded SMS: an overview of browser usage
This plugin has a minimal impact on browser resources
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,796 ▲3514.28 ▼0.071.60 ▼0.1040.81 ▼9.25
Dashboard /wp-admin2,195 ▲235.60 ▲0.0290.02 ▼11.2541.45 ▼4.93
Posts /wp-admin/edit.php2,103 ▼02.02 ▼0.0239.20 ▼4.4434.14 ▼3.48
Add New Post /wp-admin/post-new.php1,526 ▼223.00 ▲0.03651.77 ▲22.5351.21 ▼6.78
Media Library /wp-admin/upload.php1,403 ▼04.21 ▼0.0298.26 ▼2.1841.84 ▼3.62

Uninstaller [IO: ▲0.00MB] [DB: ▲0.00MB] 50% 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
  • Uninstall procedure had uncaught errors
    • > Warning in wp-includes/functions.php+6691
    file_get_contents(wp-content/plugins/woocommerce/woocommerce.php): failed to open stream: No such file or directory
  • Zombie WordPress options were found after uninstall: 6 options
    • theysaidso_admin_options
    • widget_recent-posts
    • db_upgraded
    • widget_theysaidso_widget
    • widget_recent-comments
    • can_compress_scripts

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
The smoke test was a success, however most plugin functionality was not tested

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
  • 9× PHP files trigger errors when accessed directly with GET requests:
    • > PHP Notice
      Trying to access array offset on value of type null in wp-content/plugins/branded-sms/includes/admin/funciones-formulario.php on line 11
    • > PHP Fatal error
      Uncaught Error: Call to undefined function _e() in wp-content/plugins/branded-sms/includes/formulario.php:5
    • > PHP Notice
      Trying to access array offset on value of type null in wp-content/plugins/branded-sms/includes/admin/funciones-formulario.php on line 13
    • > PHP Fatal error
      Uncaught Error: Call to undefined function __() in wp-content/plugins/branded-sms/includes/admin/funciones-formulario.php:60
    • > PHP Notice
      Trying to access array offset on value of type null in wp-content/plugins/branded-sms/includes/admin/funciones-formulario.php on line 10
    • > PHP Notice
      Trying to access array offset on value of type null in wp-content/plugins/branded-sms/includes/admin/funciones-formulario.php on line 9
    • > PHP Notice
      Trying to access array offset on value of type null in wp-content/plugins/branded-sms/includes/admin/funciones-formulario.php on line 12
    • > PHP Fatal error
      Uncaught Error: Call to undefined function _e() in wp-content/plugins/branded-sms/includes/cuadro-informacion.php:5
    • > PHP Fatal error
      Uncaught Error: Call to undefined function load_plugin_textdomain() in wp-content/plugins/branded-sms/includes/admin/funciones-apg.php:14

User-side errors Passed 1 test

🔹 Test weight: 20 | A shallow check that no browser errors were triggered
Everything seems fine on the user side

Optimizations

Plugin configuration 90% from 29 tests

readme.txt 88% from 16 tests

It's important to format your readme.txt file correctly as it is parsed for the public listing of your plugin
Attributes that require attention:
  • Tags: Please delete some tags, you are using 50 tag instead of maximum 10
  • Screenshots: These screenshots have no corresponding images in /assets: #1 (General Settings panel.), #2 (Gateways setting panel.), #3 (SMS Settings panel)
You can take inspiration from this readme.txt

branded-sms/branded-sms.php 92% from 13 tests

The main PHP script in "Branded SMS" version 4.4.3 is automatically included on every request by WordPress
Please make the necessary changes and fix the following:
  • Description: Please don't use more than 140 characters for the plugin description (currently 279 characters long)

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | This is a short overview of programming languages used in this plugin, detecting executable files
Success! There were no dangerous files found in this plugin2,882 lines of code in 13 files:
LanguageFilesBlank linesComment linesLines of code
PHP81091031,880
CSS21022672
SVG200270
Markdown116060

PHP code Passed 2 tests

Cyclomatic complexity and code structure are the fingerprint of this plugin
All good! No complexity issues found
Cyclomatic complexity
Average complexity per logical line of code0.52
Average class complexity0.00
▷ Minimum class complexity0.00
▷ Maximum class complexity0.00
Average method complexity0.00
▷ Minimum method complexity0.00
▷ Maximum method complexity0.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes0
▷ Abstract classes00.00%
▷ Concrete classes00.00%
▷ Final classes00.00%
Methods0
▷ Static methods00.00%
▷ Public methods00.00%
▷ Protected methods00.00%
▷ Private methods00.00%
Functions31
▷ Named functions31100.00%
▷ Anonymous functions00.00%
Constants1
▷ Global constants1100.00%
▷ Class constants00.00%
▷ Public constants00.00%

Plugin size Passed 2 tests

Image compression Passed 2 tests

Using a strong compression for your PNG files is a great way to speed-up your plugin
2 PNG files occupy 0.05MB with 0.03MB in potential savings
Potential savings
Compression of 2 random PNG files using pngquant
FileSize - originalSize - compressedSavings
assets/images/twizo.png22.07KB11.98KB▼ 45.73%
assets/images/logo.png24.63KB4.26KB▼ 82.72%