78% elfi-masonry-addon

Code Review | Elfi Masonry Addon for Elementor : Creating showcases for portfolios, products or post items

WordPress plugin Elfi Masonry Addon for Elementor : Creating showcases for portfolios, products or post items scored 78% from 54 tests.

About plugin

  • Plugin page: elfi-masonry-addon
  • Plugin version: 1.3.0
  • PHP compatiblity: 5.7+
  • PHP version: 7.4.16
  • WordPress compatibility: 4.7-6.2
  • WordPress version: 6.3.1
  • First release: Dec 23, 2020
  • Latest release: May 8, 2023
  • Number of updates: 21
  • Update frequency: every 41.5 days
  • Top authors: sharabindu (100%)

Code review

54 tests

User reviews

1 review

Install metrics

200+ active / 2,818 total downloads

Benchmarks

Plugin footprint 83% from 16 tests

Installer Passed 1 test

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

Server metrics [RAM: ▲0.52MB] [CPU: ▲1.04ms] Passed 4 tests

This is a short check of server-side resources used by Elfi Masonry Addon for Elementor : Creating showcases for portfolios, products or post items
This plugin has minimal impact on server resources
PageMemory (MB)CPU Time (ms)
Home /3.96 ▲0.5044.23 ▲3.88
Dashboard /wp-admin3.86 ▲0.5547.11 ▼2.23
Posts /wp-admin/edit.php3.91 ▲0.5547.03 ▲0.46
Add New Post /wp-admin/post-new.php6.49 ▲0.6087.91 ▲2.03
Media Library /wp-admin/upload.php3.72 ▲0.4940.87 ▲6.13
All Elfi Items /wp-admin/edit.php?post_type=elfi3.7636.70
Add New Elfi Item /wp-admin/post-new.php?post_type=elfi6.4787.08
How it works /wp-admin/edit.php?post_type=elfi&page=home3.6832.25
Elfi Category /wp-admin/edit-tags.php?taxonomy=el_portfolio&post_type=elfi3.7149.13

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

Input-output and database impact of this plugin
There were no storage issued detected upon installing this plugin
Filesystem: 66 new files
Database: no new tables, 6 new options
New WordPress options
db_upgraded
theysaidso_admin_options
widget_theysaidso_widget
can_compress_scripts
widget_recent-comments
widget_recent-posts

Browser metrics Passed 4 tests

An overview of browser requirements for Elfi Masonry Addon for Elementor : Creating showcases for portfolios, products or post items
This plugin has a minimal impact on browser resources
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,860 ▲10313.16 ▼1.221.68 ▼0.2145.17 ▼0.28
Dashboard /wp-admin2,260 ▲695.78 ▼0.1098.56 ▼5.5240.91 ▼7.16
Posts /wp-admin/edit.php2,145 ▲562.04 ▼0.0234.64 ▼2.7534.62 ▲0.76
Add New Post /wp-admin/post-new.php6,578 ▲5,04120.22 ▼2.88941.91 ▲299.9063.56 ▲1.34
Media Library /wp-admin/upload.php1,442 ▲544.16 ▼0.0297.96 ▼3.0745.31 ▲1.04
All Elfi Items /wp-admin/edit.php?post_type=elfi1,1142.1032.8231.15
Add New Elfi Item /wp-admin/post-new.php?post_type=elfi6,56821.49908.1139.05
How it works /wp-admin/edit.php?post_type=elfi&page=home2,37616.20522.53131.91
Elfi Category /wp-admin/edit-tags.php?taxonomy=el_portfolio&post_type=elfi1,3192.3930.5238.17

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

🔸 Tests weight: 35 | It is important to correctly uninstall your plugin, without leaving any traces
These items require your attention
  • Zombie WordPress options were found after uninstall: 6 options
    • can_compress_scripts
    • widget_recent-posts
    • db_upgraded
    • widget_recent-comments
    • widget_theysaidso_widget
    • theysaidso_admin_options

Smoke tests 50% from 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | This is a shallow check for server-side errors
Everything seems fine, however this is by no means an exhaustive test

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
  • 8× PHP files trigger errors when accessed directly with GET requests:
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_action() in wp-content/plugins/elfi-masonry-addon/includes/Class/class-elfi-admin-dashborad.php:20
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_action() in wp-content/plugins/elfi-masonry-addon/includes/metaData/class-elfi-previewlink.php:21
    • > PHP Fatal error
      Uncaught Error: Class 'Elementor\\Widget_Base' not found in wp-content/plugins/elfi-masonry-addon/includes/Elements/elfi-masonry-widget.php:8
    • > PHP Fatal error
      Uncaught Error: Class 'Elementor\\Widget_Base' not found in wp-content/plugins/elfi-masonry-addon/includes/Elements/elfi-masonry-gallery-widget.php:8
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_action() in wp-content/plugins/elfi-masonry-addon/includes/Class/class-elfi-filter.php:84
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_action() in wp-content/plugins/elfi-masonry-addon/includes/metaData/class-elfi-videodata.php:46
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_action() in wp-content/plugins/elfi-masonry-addon/includes/Class/class-elfi-permalink.php:14
    • > PHP Fatal error
      Uncaught Error: Call to undefined function esc_attr() in wp-content/plugins/elfi-masonry-addon/includes/helper/querygalleyData.php:6

User-side errors 0% from 1 test

🔹 Test weight: 20 | This is a shallow check for browser errors
Please take a look at the following user-side issues
    • > GET request to /wp-admin/edit.php?post_type=elfi&page=home
    • > Other (warning) in unknown
    /wp-admin/edit.php?post_type=elfi&page=home 200 Unrecognized feature: 'web-share'.

Optimizations

Plugin configuration 97% from 29 tests

readme.txt 94% from 16 tests

The readme.txt file is an important file in your plugin as it is parsed by WordPress.org to prepare the public listing of your plugin
Attributes that require attention:
  • Tags: Too many tags (17 tag instead of maximum 10); only the first 5 tags are used in your directory listing
You can look at the official readme.txt

elfi-masonry-addon/elfi-masonry-addon.php Passed 13 tests

"Elfi Masonry Addon for Elementor : Creating showcases for portfolios, products or post items" version 1.3.0's main PHP file describes plugin functionality and also serves as the entry point to any WordPress functionality
127 characters long description:
Elfi is a Filter masonry which allows to create attractive portfolio filters, product filters, post-filters and Gallery masonry

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | This is an overview of programming languages used in this plugin; dangerous file extensions are not allowed
Everything looks great! No dangerous files found in this plugin4,999 lines of code in 35 files:
LanguageFilesBlank linesComment linesLines of code
PHP201,1166453,478
CSS617861,425
JavaScript3221861
SVG60035

PHP code Passed 2 tests

This is a very shot review of cyclomatic complexity and code structure
This plugin has no cyclomatic complexity issues
Cyclomatic complexity
Average complexity per logical line of code0.26
Average class complexity8.00
▷ Minimum class complexity1.00
▷ Maximum class complexity41.00
Average method complexity2.38
▷ Minimum method complexity1.00
▷ Maximum method complexity41.00
Code structure
Namespaces0
Interfaces0
Traits2
Classes13
▷ Abstract classes00.00%
▷ Concrete classes13100.00%
▷ Final classes17.69%
Methods76
▷ Static methods33.95%
▷ Public methods6788.16%
▷ Protected methods67.89%
▷ Private methods33.95%
Functions22
▷ Named functions22100.00%
▷ Anonymous functions00.00%
Constants9
▷ Global constants666.67%
▷ Class constants333.33%
▷ Public constants3100.00%

Plugin size 50% from 2 tests

Image compression 50% from 2 tests

All PNG images should be compressed to minimize bandwidth usage for end users
18 PNG files occupy 1.23MB with 0.48MB in potential savings
Potential savings
Compression of 5 random PNG files using pngquant
FileSize - originalSize - compressedSavings
assets/img/filter-masonry-min.png34.76KB33.97KB▼ 2.27%
assets/img/video.png0.51KB0.51KB0.00%
assets/img/aaaaaaaa.png7.57KB3.06KB▼ 59.57%
assets/img/filsd.png196.17KB59.99KB▼ 69.42%
assets/img/masonry.png1.53KB0.56KB▼ 63.47%