90% swaypay-woocommerce

Code Review | SwayPay

WordPress plugin SwayPay scored90%from 54 tests.

About plugin

  • Plugin page: swaypay-woocommerce
  • Plugin version: 1.0.0
  • PHP version: 7.4.16
  • WordPress compatibility: 4.7.0-4.9.4
  • WordPress version: 6.3.1
  • First release: Mar 5, 2018
  • Latest release: Mar 5, 2018
  • Number of updates: 8
  • Update frequency: every 1.1 days
  • Top authors: swaypay (100%)

Code review

54 tests

User reviews

1 review

Install metrics

10+ active /576 total downloads

Benchmarks

Plugin footprint 83% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | It is important to correctly install your plugin, without throwing errors or notices
Install script ran successfully

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

Analyzing server-side resources used by SwayPay
Normal server usage
PageMemory (MB)CPU Time (ms)
Home /3.46 ▲0.0034.38 ▼7.80
Dashboard /wp-admin3.31 ▼0.0443.83 ▼18.62
Posts /wp-admin/edit.php3.36 ▲0.0049.90 ▲0.27
Add New Post /wp-admin/post-new.php5.89 ▲0.0081.70 ▼20.54
Media Library /wp-admin/upload.php3.23 ▲0.0038.15 ▲1.63

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

Analyzing filesystem and database footprints of this plugin
This plugin was installed successfully
Filesystem: 3 new files
Database: no new tables, 6 new options
New WordPress options
theysaidso_admin_options
widget_recent-posts
db_upgraded
widget_recent-comments
widget_theysaidso_widget
can_compress_scripts

Browser metrics Passed 4 tests

A check of browser resources used by SwayPay
There were no issues detected in relation to browser resource usage
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,814 ▲6814.23 ▼0.202.17 ▼0.3740.55 ▼4.71
Dashboard /wp-admin2,195 ▲185.65 ▲0.0395.49 ▼7.1643.04 ▼5.42
Posts /wp-admin/edit.php2,103 ▲32.04 ▲0.0439.94 ▼5.0835.65 ▼2.77
Add New Post /wp-admin/post-new.php1,545 ▼022.79 ▼0.41659.60 ▼7.6555.13 ▲8.21
Media Library /wp-admin/upload.php1,400 ▲34.20 ▼0.0096.39 ▼2.4742.12 ▼2.45

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

🔸 Tests weight: 35 | Verifying that this plugin uninstalls completely without leaving any traces
Please fix the following items
  • The uninstall procedure has failed, leaving 6 options in the database
    • theysaidso_admin_options
    • widget_recent-posts
    • can_compress_scripts
    • db_upgraded
    • widget_recent-comments
    • widget_theysaidso_widget

Smoke tests Passed 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | A smoke test targeting server-side errors
Even though everything seems fine, this is not 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
Congratulations! This plugin passed the SRP test

User-side errors Passed 1 test

🔹 Test weight: 20 | This is a smoke test targeting browser errors/issues
Everything seems fine on the user side

Optimizations

Plugin configuration Passed 29 tests

readme.txt Passed 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
There were no plugin tags found

swaypay-woocommerce/swaypay-woocommerce.php Passed 13 tests

The main PHP file in "SwayPay" ver. 1.0.0 adds more information about the plugin and also serves as the entry point for this plugin
34 characters long description:
SwayPay extension for WooCommerce.

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
Everything looks great! No dangerous files found in this plugin114 lines of code in 2 files:
LanguageFilesBlank linesComment linesLines of code
PHP21410114

PHP code Passed 2 tests

Analyzing cyclomatic complexity and code structure
No cyclomatic complexity issues were detected for this plugin
Cyclomatic complexity
Average complexity per logical line of code0.27
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%
Functions8
▷ Named functions675.00%
▷ Anonymous functions225.00%
Constants0
▷ Global constants00.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
There are no PNG files in this plugin