78% sms-verification-pars

Code Review | تایید اعتبار پیامکی پارس

WordPress plugin تایید اعتبار پیامکی پارس scored78%from 54 tests.

About plugin

  • Plugin page: sms-verification-...
  • Plugin version: 2.1
  • PHP version: 7.4.16
  • WordPress compatibility: 3.3-4.6.1
  • WordPress version: 6.3.1
  • First release: Sep 30, 2016
  • Latest release: Sep 30, 2016
  • Number of updates: 13
  • Update frequency: every 0.1 days
  • Top authors: mojtaba455 (100%)

Code review

54 tests

User reviews

1 review

Install metrics

10+ active /1,040 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.27MB] [CPU: ▲114.89ms] Passed 4 tests

Analyzing server-side resources used by تایید اعتبار پیامکی پارس
No issues were detected with server-side resource usage
PageMemory (MB)CPU Time (ms)
Home /3.67 ▲0.2142.95 ▲1.07
Dashboard /wp-admin3.63 ▲0.33272.64 ▲218.48
Posts /wp-admin/edit.php3.68 ▲0.33199.57 ▲144.98
Add New Post /wp-admin/post-new.php6.17 ▲0.28369.65 ▲272.97
Media Library /wp-admin/upload.php3.49 ▲0.26131.34 ▲95.01
تایید اعتبار پیامکی پارس /wp-admin/options-general.php?page=payamakpars_sms3.46175.02

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

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

Browser metrics Passed 4 tests

A check of browser resources used by تایید اعتبار پیامکی پارس
Normal browser usage
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /3,174 ▲41314.65 ▲0.3025.63 ▲23.6557.18 ▲11.23
Dashboard /wp-admin2,236 ▲596.04 ▲0.3892.08 ▲0.4841.38 ▲3.76
Posts /wp-admin/edit.php2,119 ▲222.47 ▲0.4441.95 ▲0.2937.27 ▲0.22
Add New Post /wp-admin/post-new.php1,557 ▲3123.19 ▲0.06650.72 ▼17.5641.50 ▼10.52
Media Library /wp-admin/upload.php1,441 ▲414.46 ▲0.30107.85 ▲4.5547.32 ▲3.59
تایید اعتبار پیامکی پارس /wp-admin/options-general.php?page=payamakpars_sms1,1172.3034.7982.88

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

🔸 Tests weight: 35 | Verifying that this plugin uninstalls completely without leaving any traces
It is recommended to fix the following
  • The uninstall procedure has failed, leaving 9 options in the database
    • payamakpars_sms_labels
    • can_compress_scripts
    • widget_recent-comments
    • widget_recent-posts
    • widget_theysaidso_widget
    • payamakpars_sms_gateways
    • theysaidso_admin_options
    • payamakpars_sms_options
    • db_upgraded

Smoke tests 50% from 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 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
Please fix the following items
  • 3× PHP files trigger server errors when accessed directly:
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_action() in wp-content/plugins/sms-verification-pars/ajax.php:11
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_action() in wp-content/plugins/sms-verification-pars/sms-admin.php:20
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_action() in wp-content/plugins/sms-verification-pars/ajax.php:11

User-side errors 0% from 1 test

🔹 Test weight: 20 | This is a shallow check for browser errors
Please fix the following user-side errors
    • > GET request to /wp-admin/options-general.php?page=payamakpars_sms
    • > Javascript (severe) in unknown
    /wp-content/plugins/sms-verification-pars/sms.js?ver=6.3.1 134:29 Uncaught TypeError: $(...).live is not a function

Optimizations

Plugin configuration 93% from 29 tests

readme.txt 94% from 16 tests

The readme.txt file is important because it is parsed by WordPress.org for the public listing of your plugin
Please fix the following attributes:
  • Screenshots: These screenshots do not have images: #1 (Screen shot 1), #2 (Screen shot 2), #3 (Screen shot 3), #4 (Screen shot 4), #5 (Screen shot 5), #6 (Screen shot 6), #7 (Screen shot 7)
The official readme.txt might help

sms-verification-pars/sms-validation.php 92% from 13 tests

The main PHP script in "تایید اعتبار پیامکی پارس" version 2.1 is automatically included on every request by WordPress
Please make the necessary changes and fix the following:
  • Main file name: The principal plugin file should be the same as the plugin slug ("sms-verification-pars.php" instead of "sms-validation.php")

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | An overview of files in this plugin; executable files are not allowed
There were no executable files found in this plugin1,446 lines of code in 7 files:
LanguageFilesBlank linesComment linesLines of code
PHP5267237933
CSS13965385
JavaScript1184128

PHP code Passed 2 tests

Analyzing cyclomatic complexity and code structure
There were no cyclomatic complexity issued detected
Cyclomatic complexity
Average complexity per logical line of code0.28
Average class complexity16.80
▷ Minimum class complexity2.00
▷ Maximum class complexity41.00
Average method complexity2.46
▷ Minimum method complexity1.00
▷ Maximum method complexity11.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes5
▷ Abstract classes00.00%
▷ Concrete classes5100.00%
▷ Final classes00.00%
Methods54
▷ Static methods35.56%
▷ Public methods54100.00%
▷ Protected methods00.00%
▷ Private methods00.00%
Functions10
▷ Named functions10100.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
7 PNG files occupy 0.23MB with 0.13MB in potential savings
Potential savings
Compression of 5 random PNG files using pngquant
FileSize - originalSize - compressedSavings
screenshot-4.png26.02KB10.92KB▼ 58.02%
screenshot-5.png75.44KB34.12KB▼ 54.77%
screenshot-1.png32.53KB14.62KB▼ 55.08%
screenshot-2.png34.20KB14.72KB▼ 56.96%
screenshot-7.png11.46KB5.13KB▼ 55.19%