67% cloud-rebue-wpsms

Code Review | cloudrebuesms

WordPress plugin cloudrebuesms scored67%from 54 tests.

About plugin

  • Plugin page: cloud-rebue-wpsms
  • Plugin version: 1.0.9
  • PHP compatiblity: 7.0+
  • PHP version: 7.4.16
  • WordPress compatibility: 4.6-6.4.1
  • WordPress version: 6.3.1
  • First release: Apr 21, 2021
  • Latest release: Nov 10, 2023
  • Number of updates: 28
  • Update frequency: every 33.3 days
  • Top authors: cloudrebue (100%)

Code review

54 tests

User reviews

1 review

Install metrics

10+ active /1,004 total downloads

Benchmarks

Plugin footprint 65% from 16 tests

Installer Passed 1 test

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

Server metrics [RAM: ▲0.16MB] [CPU: ▼2.31ms] Passed 4 tests

An overview of server-side resources used by cloudrebuesms
This plugin has minimal impact on server resources
PageMemory (MB)CPU Time (ms)
Home /3.74 ▲0.2837.22 ▼3.32
Dashboard /wp-admin3.45 ▲0.1445.97 ▼3.83
Posts /wp-admin/edit.php3.56 ▲0.2051.27 ▲5.81
Add New Post /wp-admin/post-new.php6.05 ▲0.1684.54 ▼6.49
Media Library /wp-admin/upload.php3.37 ▲0.1438.50 ▲4.39
Log History /wp-admin/admin.php?page=sms_notifications_log_history3.3333.73
Cloud Rebue /wp-admin/options-general.php?page=cloudrebuesms3.4232.77
Cloud Rebue /wp-admin/admin.php?page=cloudrebuesms3.4232.99

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

How much does this plugin use your filesystem and database?
No storage issues were detected
Filesystem: 48 new files
Database: 1 new table, 6 new options
New tables
wp_crsms_logs
New WordPress options
db_upgraded
can_compress_scripts
widget_recent-posts
widget_recent-comments
widget_theysaidso_widget
theysaidso_admin_options

Browser metrics Passed 4 tests

An overview of browser requirements for cloudrebuesms
Minimal impact on browser resources
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,863 ▲10113.20 ▼1.154.65 ▲2.8835.93 ▼7.43
Dashboard /wp-admin2,251 ▲745.79 ▲0.1698.38 ▼0.8838.63 ▼7.00
Posts /wp-admin/edit.php2,162 ▲592.41 ▲0.3939.49 ▲3.7237.90 ▲2.66
Add New Post /wp-admin/post-new.php1,480 ▼4622.14 ▼0.84564.69 ▼95.9832.19 ▼17.45
Media Library /wp-admin/upload.php1,459 ▲594.45 ▲0.23103.17 ▲0.5238.75 ▼8.83
Log History /wp-admin/admin.php?page=sms_notifications_log_history1,3112.8253.4758.50
Cloud Rebue /wp-admin/options-general.php?page=cloudrebuesms1,1421.9834.2838.56
Cloud Rebue /wp-admin/admin.php?page=cloudrebuesms1,0992.0030.7731.61

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

🔸 Tests weight: 35 | Verifying that this plugin uninstalls completely without leaving any traces
Please fix the following items
  • The plugin did not uninstall successfully, leaving 1 table in the database
    • wp_crsms_logs
  • Zombie WordPress options were found after uninstall: 6 options
    • theysaidso_admin_options
    • can_compress_scripts
    • widget_recent-comments
    • widget_theysaidso_widget
    • db_upgraded
    • widget_recent-posts

Smoke tests 50% from 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | Just a short smoke test targeting errors on the server (in the Apache logs)
Even though no errors were found, this is by no means an exhaustive test

SRP 50% from 2 tests

🔹 Tests weight: 20 | It is important to ensure that your PHP files perform no action when accessed directly, respecting the single-responsibility principle
Almost there! Just fix the following items
  • 10× PHP files output text when accessed directly:
    • > /wp-content/plugins/cloud-rebue-wpsms/tpl/log_page.php
    • > /wp-content/plugins/cloud-rebue-wpsms/inc/security_two_factor.php
    • > /wp-content/plugins/cloud-rebue-wpsms/tpl/settings_page.php
    • > /wp-content/plugins/cloud-rebue-wpsms/templates/settings_page.php
    • > /wp-content/plugins/cloud-rebue-wpsms/inc/admin_widget_menu.php
    • > /wp-content/plugins/cloud-rebue-wpsms/inc/shortcode.php
    • > /wp-content/plugins/cloud-rebue-wpsms/cloudrebuesms.php
    • > /wp-content/plugins/cloud-rebue-wpsms/tpl/wp-login-add-phone.php
    • > /wp-content/plugins/cloud-rebue-wpsms/tpl/wp-login-confirm-phone.php
    • > /wp-content/plugins/cloud-rebue-wpsms/tpl/wp-login-confirmed-phone.php

User-side errors 0% from 1 test

🔹 Test weight: 20 | A shallow check that no browser errors were triggered
These are user-side errors you should fix
  • 3 occurences, only the last one shown
    • > GET request to /wp-admin/admin.php?page=cloudrebuesms
    • > Console-api (warning) in unknown
    /wp-admin/load-scripts.php?c=0&load%5Bchunk_0%5D=jquery-core,jquery-migrate,utils&ver=6.3.1 1:28609 "jQuery.Deferred exception: $(...).tabs is not a function" "TypeError: $(...).tabs is not a function\n at HTMLDocument.\u003Canonymous> (/wp-content/plugins/cloud-rebue-wpsms/crsmsjs/crsms.js?ver=6.3.1:10:6)\n at e (/wp-admin/load-scripts.php?c=0&load%5Bchunk_0%5D=jquery-core,jquery-migrate,utils&ver=6.3.1:2:26990)\n at t (/wp-admin/load-scripts.php?c=0&load%5Bchunk_0%5D=jquery-core,jquery-migrate,utils&ver=6.3.1:2:27292)" undefined
  • 3 occurences, only the last one shown
    • > GET request to /wp-admin/admin.php?page=cloudrebuesms
    • > Javascript (severe) in unknown
    /wp-admin/load-scripts.php?c=0&load%5Bchunk_0%5D=jquery-core,jquery-migrate,utils&ver=6.3.1 1:28721 Uncaught TypeError: $(...).tabs is not a function

Optimizations

Plugin configuration 86% from 29 tests

readme.txt 94% from 16 tests

You should put a lot of thought into formatting readme.txt as it is used by WordPress.org to prepare the public listing of your plugin
Please fix the following attributes:
  • Screenshots: These screenshots do not have images: #21 (Access Token.), #22 (Woo-Notifications.)
You can look at the official readme.txt

cloud-rebue-wpsms/cloudrebuesms.php 77% from 13 tests

The main PHP script in "cloudrebuesms" version 1.0.9 is automatically included on every request by WordPress
You should first fix the following items:
  • Requires at least: Required version must be the same as the one declared in readme.txt ("5.6.0" instead of "4.6")
  • Text Domain: Since WordPress version 4.6 the text domain is optional; if specified, it must be the same as the plugin slug
  • Main file name: It is recommended to name the main PHP file as the plugin slug ("cloud-rebue-wpsms.php" instead of "cloudrebuesms.php")

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | A short glimpse at programming languages used with this plugin and a check that no dangerous files are present
Success! There were no dangerous files found in this plugin4,597 lines of code in 26 files:
LanguageFilesBlank linesComment linesLines of code
PHP123103041,767
CSS6295481,429
JavaScript62391161,387
SVG11013
JSON1001

PHP code Passed 2 tests

An short overview of logical lines of code, cyclomatic complexity, and other code metrics
All good! No complexity issues found
Cyclomatic complexity
Average complexity per logical line of code0.27
Average class complexity15.25
▷ Minimum class complexity6.00
▷ Maximum class complexity36.00
Average method complexity3.04
▷ Minimum method complexity1.00
▷ Maximum method complexity7.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes4
▷ Abstract classes00.00%
▷ Concrete classes4100.00%
▷ Final classes00.00%
Methods29
▷ Static methods29100.00%
▷ Public methods2482.76%
▷ Protected methods00.00%
▷ Private methods517.24%
Functions38
▷ Named functions2668.42%
▷ Anonymous functions1231.58%
Constants8
▷ Global constants337.50%
▷ Class constants562.50%
▷ Public constants5100.00%

Plugin size Passed 2 tests

Image compression Passed 2 tests

All PNG images should be compressed to minimize bandwidth usage for end users
12 PNG files occupy 0.35MB with 0.20MB in potential savings
Potential savings
Compression of 5 random PNG files using pngquant
FileSize - originalSize - compressedSavings
Screenshot_2.png15.28KB8.65KB▼ 43.37%
icon-128x128.png6.55KB2.64KB▼ 59.64%
img/icon-128x128.png6.55KB2.64KB▼ 59.64%
icon-256x256.png12.87KB5.36KB▼ 58.39%
logo.png17.98KB6.95KB▼ 61.35%