74% rays-grid

Code Review | RAYS Grid

WordPress plugin RAYS Grid scored 74% from 54 tests.

About plugin

  • Plugin page: rays-grid
  • Plugin version: 1.3.1
  • PHP version: 7.4.16
  • WordPress version: 6.3.1
  • First release: Dec 13, 2017
  • Latest release: Jan 28, 2022
  • Number of updates: 68
  • Update frequency: every 22.2 days
  • Top authors: IT-RAYS (100%)

Code review

54 tests

User reviews

5 reviews

Install metrics

900+ active / 11,864 total downloads

Benchmarks

Plugin footprint 65% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | All plugins must install correctly, without throwing any errors, warnings, or notices
Install script ran successfully

Server metrics [RAM: ▲0.47MB] [CPU: ▼0.41ms] Passed 4 tests

This is a short check of server-side resources used by RAYS Grid
Server-side resource usage in normal parameters
PageMemory (MB)CPU Time (ms)
Home /3.90 ▲0.4444.51 ▼1.76
Dashboard /wp-admin3.76 ▲0.4646.29 ▼3.61
Posts /wp-admin/edit.php3.86 ▲0.5060.73 ▲16.13
Add New Post /wp-admin/post-new.php6.55 ▲0.6787.44 ▲1.27
Media Library /wp-admin/upload.php3.72 ▲0.4938.04 ▲2.45
Add New /wp-admin/admin.php?page=raysgrid&do=create3.8442.99
Categories /wp-admin/edit-tags.php?taxonomy=raysgrid_categories&post_type=raysgridpost3.6636.92
Tags /wp-admin/edit-tags.php?taxonomy=raysgrid_tags&post_type=raysgridpost3.6636.18
Portfolio Posts /wp-admin/edit.php?post_type=raysgridpost3.7037.89
Import/Export /wp-admin/admin.php?page=raysgrid-exp3.6032.17
Add New /wp-admin/post-new.php?post_type=raysgridpost6.5580.23
RAYS Grid /wp-admin/admin.php?page=raysgrid3.6736.15

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

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

Browser metrics Passed 4 tests

A check of browser resources used by RAYS Grid
This plugin has a minimal impact on browser resources
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /3,166 ▲43114.60 ▲0.3817.62 ▲15.7444.96 ▼1.51
Dashboard /wp-admin2,322 ▲1315.48 ▼0.55108.47 ▼10.94104.63 ▲58.81
Posts /wp-admin/edit.php2,213 ▲1242.43 ▲0.3945.37 ▲9.6252.77 ▲17.55
Add New Post /wp-admin/post-new.php1,600 ▲7123.56 ▲0.34715.84 ▲26.2542.25 ▼5.45
Media Library /wp-admin/upload.php1,489 ▲1014.76 ▲0.60104.30 ▲3.22103.16 ▲58.99
Add New /wp-admin/admin.php?page=raysgrid&do=create3,0013.6688.8285.71
Categories /wp-admin/edit-tags.php?taxonomy=raysgrid_categories&post_type=raysgridpost1,3832.4137.0952.32
Tags /wp-admin/edit-tags.php?taxonomy=raysgrid_tags&post_type=raysgridpost1,3582.4133.2347.67
Portfolio Posts /wp-admin/edit.php?post_type=raysgridpost1,1832.3538.3667.05
Import/Export /wp-admin/admin.php?page=raysgrid-exp9862.3033.9557.15
Add New /wp-admin/post-new.php?post_type=raysgridpost6,52526.98898.5136.61
RAYS Grid /wp-admin/admin.php?page=raysgrid9462.2833.6782.33

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

🔸 Tests weight: 35 | Verifying that this plugin uninstalls completely without leaving any traces
It is recommended to fix the following
  • This plugin cannot be uninstalled
    • > Deprecated in wp-includes/class-wp-hook.php+310
    Non-static method raysgrid_Base::rsgd_uninstall() should not be called statically
  • This plugin does not fully uninstall, leaving 6 options in the database
    • can_compress_scripts
    • widget_recent-posts
    • widget_recent-comments
    • theysaidso_admin_options
    • db_upgraded
    • widget_theysaidso_widget

Smoke tests 75% from 4 tests

Server-side errors 0% from 1 test

🔹 Test weight: 20 | A smoke test targeting server-side errors
These errors were triggered by the plugin
    • > GET request to /wp-admin/admin.php?page=raysgrid-exp
    • > Notice in wp-content/plugins/rays-grid/includes/class-db.php+280
    Undefined index: rsgd_nonce_fields
    • > GET request to /wp-admin/admin.php?page=raysgrid-exp
    • > Notice in wp-content/plugins/rays-grid/includes/class-db.php+296
    Undefined index: importfile
    • > GET request to /wp-admin/admin.php?page=raysgrid-exp
    • > Notice in wp-content/plugins/rays-grid/includes/class-db.php+296
    Trying to access array offset on value of type null

SRP Passed 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
Everything seems fine, however this is by no means an exhaustive test

User-side errors Passed 1 test

🔹 Test weight: 20 | This is a shallow check for browser errors
No browser errors were detected

Optimizations

Plugin configuration Passed 29 tests

readme.txt Passed 16 tests

Perhaps the most important file in your plugin readme.txt gets parsed in order to generate the public listing of your plugin
No plugin tags provided

rays-grid/rays-grid.php Passed 13 tests

The principal PHP file in "RAYS Grid" v. 1.3.1 is loaded by WordPress automatically on each request
54 characters long description:
WordPress Plugin for showing Grids with Custom Styles.

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | This is an overview of file extensions present in this plugin and a short test that no dangerous files are bundled with this plugin
Everything looks great! No dangerous files found in this plugin12,001 lines of code in 40 files:
LanguageFilesBlank linesComment linesLines of code
CSS879704,828
SVG3003,898
PHP17376412,010
JavaScript123621261,265

PHP code Passed 2 tests

This is a very shot review of cyclomatic complexity and code structure
There were no cyclomatic complexity issued detected
Cyclomatic complexity
Average complexity per logical line of code0.35
Average class complexity18.57
▷ Minimum class complexity1.00
▷ Maximum class complexity46.00
Average method complexity3.98
▷ Minimum method complexity1.00
▷ Maximum method complexity28.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes7
▷ Abstract classes00.00%
▷ Concrete classes7100.00%
▷ Final classes00.00%
Methods42
▷ Static methods49.52%
▷ Public methods42100.00%
▷ Protected methods00.00%
▷ Private methods00.00%
Functions9
▷ Named functions9100.00%
▷ Anonymous functions00.00%
Constants6
▷ Global constants6100.00%
▷ Class constants00.00%
▷ Public constants00.00%

Plugin size Passed 2 tests

Image compression Passed 2 tests

All PNG images should be compressed to minimize bandwidth usage for end users
7 PNG files occupy 0.01MB with 0.00MB in potential savings
Potential savings
Compression of 5 random PNG files using pngquant
FileSize - originalSize - compressedSavings
assets/public/css/images/overlay.png0.11KB0.15KB0.00%
assets/public/css/images/loading_background.png0.13KB0.15KB0.00%
assets/admin/images/logo.png5.71KB2.73KB▼ 52.20%
assets/admin/images/ico.png1.44KB0.79KB▼ 45.24%
assets/admin/images/short-logo.png3.21KB1.73KB▼ 46.07%