84% limepay-woocommerce-gateway

Code Review | Limepay WooCommerce Gateway

WordPress plugin Limepay WooCommerce Gateway scored84%from 54 tests.

About plugin

  • Plugin page: limepay-woocommer...
  • Plugin version: 3.0.3
  • PHP version: 7.4.16
  • WordPress version: 6.3.1
  • First release: Oct 16, 2018
  • Latest release: Sep 22, 2021
  • Number of updates: 58
  • Update frequency: every 18.5 days
  • Top authors: limepay (100%)

Code review

54 tests

User reviews

1 review

Install metrics

80+ active /2,309 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
This plugin's installer ran successfully

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

A check of server-side resources used by Limepay WooCommerce Gateway
This plugin does not affect your website's performance
PageMemory (MB)CPU Time (ms)
Home /3.47 ▲0.0138.19 ▲2.35
Dashboard /wp-admin3.31 ▲0.0142.61 ▼1.76
Posts /wp-admin/edit.php3.36 ▲0.0045.88 ▼2.26
Add New Post /wp-admin/post-new.php5.89 ▲0.0087.62 ▼12.13
Media Library /wp-admin/upload.php3.23 ▲0.0036.29 ▲4.34

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

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

Browser metrics Passed 4 tests

A check of browser resources used by Limepay WooCommerce Gateway
This plugin renders optimally with no browser resource issues detected
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,883 ▲12613.97 ▼0.837.69 ▲5.7637.55 ▼3.11
Dashboard /wp-admin2,200 ▲125.83 ▲0.90108.02 ▼8.8649.01 ▲3.44
Posts /wp-admin/edit.php2,089 ▼02.05 ▲0.0939.43 ▼6.2034.99 ▼2.56
Add New Post /wp-admin/post-new.php1,514 ▼3117.72 ▼0.26650.10 ▲30.5461.46 ▲3.86
Media Library /wp-admin/upload.php1,382 ▼94.24 ▲0.0496.74 ▼6.8441.52 ▼0.16

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

🔸 Tests weight: 35 | All plugins must uninstall correctly, removing their source code and extra database tables they might have created
You still need to fix the following
  • This plugin did not uninstall successfully, leaving 6 options in the database
    • theysaidso_admin_options
    • can_compress_scripts
    • widget_theysaidso_widget
    • widget_recent-comments
    • widget_recent-posts
    • db_upgraded

Smoke tests 75% 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 | The single-responsibility principle applies for WordPress plugins as well - please make sure your PHP files perform no actions when accessed directly
Please fix the following
  • 2× PHP files trigger server errors when accessed directly:
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_action() in wp-content/plugins/limepay-woocommerce-gateway/woocommerce-gateway-limepay.php:14
    • > PHP Fatal error
      Uncaught Error: Class 'WC_Payment_Gateway' not found in wp-content/plugins/limepay-woocommerce-gateway/woocommerce-limepay.php:3

User-side errors Passed 1 test

🔹 Test weight: 20 | This is just a short smoke test looking for browser issues
There were no browser issues found

Optimizations

Plugin configuration 93% from 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
4 plugin tags: split payments, debit card, checkout, credit card

limepay-woocommerce-gateway/woocommerce-gateway-limepay.php 85% from 13 tests

The principal PHP file in "Limepay WooCommerce Gateway" v. 3.0.3 is loaded by WordPress automatically on each request
Please take the time to fix the following:
  • Main file name: Name the main plugin file the same as the plugin slug ("limepay-woocommerce-gateway.php" instead of "woocommerce-gateway-limepay.php")
  • Text Domain: If you choose to specify the text domain, it must be the same as the plugin slug; optional since WordPress version 4.6

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
Success! There were no dangerous files found in this plugin964 lines of code in 6 files:
LanguageFilesBlank linesComment linesLines of code
PHP29766499
CSS13212291
JavaScript2238112
Markdown133062

PHP code Passed 2 tests

Cyclomatic complexity and code structure are the fingerprint of this plugin
No cyclomatic complexity issues were detected for this plugin
Cyclomatic complexity
Average complexity per logical line of code0.39
Average class complexity50.00
▷ Minimum class complexity50.00
▷ Maximum class complexity50.00
Average method complexity3.88
▷ Minimum method complexity1.00
▷ Maximum method complexity10.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes1
▷ Abstract classes00.00%
▷ Concrete classes1100.00%
▷ Final classes00.00%
Methods17
▷ Static methods00.00%
▷ Public methods952.94%
▷ Protected methods00.00%
▷ Private methods847.06%
Functions9
▷ Named functions9100.00%
▷ Anonymous functions00.00%
Constants0
▷ Global constants00.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
No PNG images were found in this plugin