78% rms-interaction

Code Review | RMS Affiliate

WordPress plugin RMS Affiliate scored 78% from 54 tests.

About plugin

  • Plugin page: rms-interaction
  • Plugin version: 4.1.3.0
  • PHP compatiblity: 5.2.4+
  • PHP version: 7.4.16
  • WordPress compatibility: 1.6.1-5.0.1
  • WordPress version: 5.9.2
  • First release: Oct 1, 2018
  • Latest release: Nov 11, 2019
  • Number of updates: 43
  • Update frequency: every 9.5 days
  • Top authors: devnetvietnam (100%)

Code review

54 tests

User reviews

1 review

Install metrics

10+ active / 1,091 total downloads

Benchmarks

Plugin footprint 83% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | Checking the installer triggered no errors
The plugin installed gracefully, with no errors

Server metrics [RAM: ▲0.08MB] [CPU: ▼293.94ms] Passed 4 tests

Server-side resources used by RMS Affiliate
No issues were detected with server-side resource usage
PageMemory (MB)CPU Time (ms)
Home /3.61 ▲0.1058.24 ▲5.54
Dashboard /wp-admin3.52 ▲0.1135.22 ▲1.06
Posts /wp-admin/edit.php3.74 ▲0.1039.72 ▼0.66
Add New Post /wp-admin/post-new.php6.98 ▲0.02102.92 ▼1,181.69
Media Library /wp-admin/upload.php3.40 ▲0.1052.88 ▲22.78
Màu sắc /wp-admin/admin.php?page=color-setting-RM3.3723.96
Kết nối /wp-admin/admin.php?page=rms-config3.3724.88
Kết nối GetResponce /wp-admin/admin.php?page=rms-config-getresponce3.3723.88
Thông báo CTV /wp-admin/admin.php?page=rms-notification-aff3.3523.91
Cấu hình share link /wp-admin/admin.php?page=rms-config-sharelink3.3734.78
Form mua hàng /wp-admin/admin.php?page=rms-manage-form-order3.4334.04
Email thông báo /wp-admin/admin.php?page=rms-edit-email3.4538.97
Mã nhúng /wp-admin/admin.php?page=rms-manage-link-shortcode3.3525.87
Bitly Shortlink /wp-admin/admin.php?page=rms-bitly_shortlink3.3723.31
Tùy chỉnh CSS /wp-admin/admin.php?page=rms-custom-css3.3726.89

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

A short overview of filesystem and database impact
The plugin installed successfully
Filesystem: 91 new files
Database: 5 new tables, no new options
New tables
wp_rms_infusionsoft
wp_rms_order_form_log
wp_rms_notification_aff_setting
wp_rms_email_setting
wp_rms_order_form

Browser metrics Passed 4 tests

An overview of browser requirements for RMS Affiliate
Normal browser usage
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /4,001 ▲24717.01 ▲1.3812.25 ▲6.222.22 ▲0.02
Dashboard /wp-admin3,001 ▲1506.78 ▲0.61121.30 ▼20.32166.05 ▲6.48
Posts /wp-admin/edit.php2,797 ▲1063.32 ▲0.0891.13 ▲25.58148.53 ▼5.26
Add New Post /wp-admin/post-new.php1,702 ▲4118.81 ▲1.78397.71 ▼9.10158.54 ▲1.03
Media Library /wp-admin/upload.php1,806 ▲1086.19 ▲0.67129.58 ▼17.18197.51 ▲13.38
Màu sắc /wp-admin/admin.php?page=color-setting-RM1,1413.1656.95165.13
Kết nối /wp-admin/admin.php?page=rms-config1,3773.1660.30170.72
Kết nối GetResponce /wp-admin/admin.php?page=rms-config-getresponce1,1653.1555.24151.56
Thông báo CTV /wp-admin/admin.php?page=rms-notification-aff2,0979.08158.25181.06
Cấu hình share link /wp-admin/admin.php?page=rms-config-sharelink1,1763.1659.31150.55
Form mua hàng /wp-admin/admin.php?page=rms-manage-form-order2,7879.44166.12249.82
Email thông báo /wp-admin/admin.php?page=rms-edit-email2,27210.48164.44226.76
Mã nhúng /wp-admin/admin.php?page=rms-manage-link-shortcode1,1323.1654.65142.18
Bitly Shortlink /wp-admin/admin.php?page=rms-bitly_shortlink1,1543.1856.99137.42
Tùy chỉnh CSS /wp-admin/admin.php?page=rms-custom-css1,1093.1858.83174.49

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

🔸 Tests weight: 35 | Checking the uninstaller removed all traces of the plugin
Please fix the following items
  • The uninstall procedure failed, leaving 5 tables in the database
    • wp_rms_notification_aff_setting
    • wp_rms_infusionsoft
    • wp_rms_email_setting
    • wp_rms_order_form_log
    • wp_rms_order_form

Smoke tests 50% from 4 tests

Server-side errors 0% from 1 test

🔹 Test weight: 20 | This is a shallow check for server-side errors
Smoke test failed, please fix the following
    • > GET request to /wp-admin/admin.php?page=rms-notification-aff
    • > Notice in wp-content/plugins/rms-interaction/app/views/NotificationAffSuccessView.php+22
    Undefined property: stdClass::$id
    • > GET request to /wp-admin/admin.php?page=rms-manage-link-shortcode
    • > Notice in wp-content/plugins/rms-interaction/app/boot/BackEnd.php+100
    Undefined index: shortcode_id

SRP 50% from 2 tests

🔹 Tests weight: 20 | The single-responsibility principle: PHP files have to remain inert when accessed directly, throwing no errors and performing no actions
Please fix the following items
  • 2× PHP files trigger server errors when accessed directly:
    • > PHP Fatal error
      Uncaught Error: Call to undefined function plugins_url() in wp-content/plugins/rms-interaction/loader.php:51
    • > PHP Fatal error
      Uncaught Error: Call to undefined function plugins_url() in wp-content/plugins/rms-interaction/loader.php:51

User-side errors Passed 1 test

🔹 Test weight: 20 | A shallow check that no browser errors were triggered
No browser issues were found

Optimizations

Plugin configuration 90% from 29 tests

readme.txt 94% from 16 tests

Perhaps the most important file in your plugin readme.txt gets parsed in order to generate the public listing of your plugin
These attributes need your attention:
  • Screenshots: Screenshot #1 (http://rms.com.vn/wp-content/uploads/2018/10/banner-772×250.jpg) image missing
The official readme.txt might help

rms-interaction/rms.php 85% from 13 tests

The main file in "RMS Affiliate" v. 4.1.3.0 serves as a complement to information provided in readme.txt and as the entry point to the plugin
You should first fix the following items:
  • Main file name: Even though not officially enforced, the main plugin file should be the same as the plugin slug ("rms-interaction.php" instead of "rms.php")
  • Description: Please use more than 10 characters for the plugin description (currently 0 characters long)

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | A short check of programming languages and file extensions; no executable files are allowed
There were no executable files found in this plugin12,531 lines of code in 76 files:
LanguageFilesBlank linesComment linesLines of code
CSS9599694,497
PHP456788614,157
JavaScript165162162,819
SVG200818
HTML120168
INI25071
Markdown1001

PHP code Passed 2 tests

Analyzing logical lines of code, cyclomatic complexity, and other code metrics
There are no cyclomatic complexity problems detected for this plugin
Cyclomatic complexity
Average complexity per logical line of code0.33
Average class complexity10.72
▷ Minimum class complexity1.00
▷ Maximum class complexity134.00
Average method complexity3.17
▷ Minimum method complexity1.00
▷ Maximum method complexity77.00
Code structure
Namespaces4
Interfaces0
Traits0
Classes43
▷ Abstract classes00.00%
▷ Concrete classes43100.00%
▷ Final classes00.00%
Methods187
▷ Static methods2915.51%
▷ Public methods18498.40%
▷ Protected methods21.07%
▷ Private methods10.53%
Functions5
▷ Named functions360.00%
▷ Anonymous functions240.00%
Constants14
▷ Global constants535.71%
▷ Class constants964.29%
▷ Public constants9100.00%

Plugin size Passed 2 tests

Image compression Passed 2 tests

All PNG images should be compressed to minimize bandwidth usage for end users
4 compressed PNG files occupy 0.01MB
Potential savings
Compression of 4 random PNG files using pngquant
FileSize - originalSize - compressedSavings
assets/images/tooltip.png0.60KB0.54KB▼ 9.15%
assets/images/share.png7.28KB4.38KB▼ 39.93%
assets/images/remove.png0.32KB0.41KB0.00%
assets/css/chosen-sprite.png0.51KB0.88KB0.00%