84% ryspayhn-gateway

Code Review | Ryspayhn-Gateways

WordPress plugin Ryspayhn-Gateways scored84%from 54 tests.

About plugin

  • Plugin page: ryspayhn-gateway
  • Plugin version: 1.6.0
  • PHP compatiblity: 7.2+
  • PHP version: 7.4.16
  • WordPress compatibility: 5.3.2-5.3.2
  • WordPress version: 6.3.1
  • First release: Feb 13, 2020
  • Latest release: Apr 22, 2020
  • Number of updates: 10
  • Update frequency: every 6.9 days
  • Top authors: cro22 (100%)

Code review

54 tests

User reviews

1 review

Install metrics

10+ active /516 total downloads

Benchmarks

Plugin footprint 83% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | The install procedure must perform silently
The plugin installed gracefully, with no errors

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

Server-side resources used by Ryspayhn-Gateways
This plugin does not affect your website's performance
PageMemory (MB)CPU Time (ms)
Home /3.46 ▲0.0034.62 ▼0.64
Dashboard /wp-admin3.31 ▲0.0042.91 ▼3.06
Posts /wp-admin/edit.php3.36 ▲0.0048.77 ▲4.87
Add New Post /wp-admin/post-new.php5.89 ▲0.0088.69 ▼18.08
Media Library /wp-admin/upload.php3.23 ▲0.0035.29 ▲0.65

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

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

Browser metrics Passed 4 tests

A check of browser resources used by Ryspayhn-Gateways
This plugin renders optimally with no browser resource issues detected
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,789 ▲2814.28 ▼0.351.60 ▲0.0443.90 ▲5.50
Dashboard /wp-admin2,198 ▲295.62 ▼0.0988.63 ▼12.1939.79 ▼5.01
Posts /wp-admin/edit.php2,100 ▲31.97 ▼0.0339.44 ▲5.3034.84 ▼2.32
Add New Post /wp-admin/post-new.php1,526 ▼223.11 ▼0.02664.80 ▼2.1150.26 ▼5.02
Media Library /wp-admin/upload.php1,400 ▼04.17 ▲0.0395.54 ▼5.3144.01 ▲1.36

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

🔸 Tests weight: 35 | Checking the uninstaller removed all traces of the plugin
These items require your attention
  • The uninstall procedure has failed, leaving 6 options in the database
    • theysaidso_admin_options
    • db_upgraded
    • widget_recent-comments
    • can_compress_scripts
    • widget_theysaidso_widget
    • widget_recent-posts

Smoke tests 75% from 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | This is a shallow check for server-side errors
The smoke test was a success, however most plugin functionality was not tested

SRP 50% from 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
Almost there! Just fix the following items
  • 4× PHP files trigger server errors when accessed directly:
    • > PHP Warning
      Use of undefined constant ABSPATH - assumed 'ABSPATH' (this will throw an Error in a future version of PHP) in wp-content/plugins/ryspayhn-gateway/include/lib/active_ryspayhn.php on line 3
    • > PHP Fatal error
      Uncaught Error: Call to undefined function plugin_dir_path() in wp-content/plugins/ryspayhn-gateway/include/menu/menu_ryspayhn.php:8
    • > PHP Warning
      require_once(ABSPATHwp-admin/includes/plugin.php): failed to open stream: No such file or directory in wp-content/plugins/ryspayhn-gateway/include/lib/active_ryspayhn.php on line 3
    • > PHP Fatal error
      require_once(): Failed opening required 'ABSPATHwp-admin/includes/plugin.php' (include_path='.:/usr/share/php') in wp-content/plugins/ryspayhn-gateway/include/lib/active_ryspayhn.php on line 3

User-side errors Passed 1 test

🔹 Test weight: 20 | This is a smoke test targeting browser errors/issues
There were no browser issues found

Optimizations

Plugin configuration 96% 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
5 plugin tags: paygate, ecommerce, gateway, payment, woocommerce

ryspayhn-gateway/ryspayhn.php 92% from 13 tests

The primary PHP file in "Ryspayhn-Gateways" version 1.6.0 is used by WordPress to initiate all plugin functionality
You should first fix the following items:
  • Main file name: It is recommended to name the main PHP file as the plugin slug ("ryspayhn-gateway.php" instead of "ryspayhn.php")

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | There should be no dangerous file extensions present in any WordPress plugin
Good job! No executable or dangerous file extensions detected17,984 lines of code in 12 files:
LanguageFilesBlank linesComment linesLines of code
JavaScript31,1511,4979,508
CSS21,09477,930
PHP74742546

PHP code Passed 2 tests

An short overview of logical lines of code, cyclomatic complexity, and other code metrics
This plugin has no cyclomatic complexity issues
Cyclomatic complexity
Average complexity per logical line of code0.21
Average class complexity18.00
▷ Minimum class complexity3.00
▷ Maximum class complexity33.00
Average method complexity3.00
▷ Minimum method complexity1.00
▷ Maximum method complexity13.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes2
▷ Abstract classes00.00%
▷ Concrete classes2100.00%
▷ Final classes00.00%
Methods17
▷ Static methods00.00%
▷ Public methods1482.35%
▷ Protected methods00.00%
▷ Private methods317.65%
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

It is recommended to compress PNG files in your plugin to minimize bandwidth usage
No PNG files were detected