84% alley-elementor-widget

Code Review | Alley Elementor Widget

WordPress plugin Alley Elementor Widget scored84%from 54 tests.

About plugin

  • Plugin page: alley-elementor-w...
  • Plugin version: 1.0.7
  • PHP compatiblity: 7.0+
  • PHP version: 7.4.16
  • WordPress compatibility: 5.0.0-6.0.0
  • WordPress version: 6.3.1
  • First release: Feb 3, 2021
  • Latest release: Jun 10, 2022
  • Number of updates: 13
  • Update frequency: every 37.9 days
  • Top authors: alleythemes (100%)

Code review

54 tests

User reviews

1 review

Install metrics

200+ active /4,394 total downloads

Benchmarks

Plugin footprint 83% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | The install procedure must perform silently
Installer ran successfully

Server metrics [RAM: ▲0.02MB] [CPU: ▼2.97ms] Passed 4 tests

Server-side resources used by Alley Elementor Widget
Normal server usage
PageMemory (MB)CPU Time (ms)
Home /3.48 ▲0.0239.46 ▲2.47
Dashboard /wp-admin3.32 ▲0.0244.75 ▼4.65
Posts /wp-admin/edit.php3.37 ▲0.0248.84 ▲4.73
Add New Post /wp-admin/post-new.php5.90 ▲0.0284.30 ▼10.72
Media Library /wp-admin/upload.php3.25 ▲0.0233.56 ▲1.03

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

Input-output and database impact of this plugin
No storage issues were detected
Filesystem: 26 new files
Database: no new tables, 6 new options
New WordPress options
widget_recent-posts
can_compress_scripts
widget_theysaidso_widget
widget_recent-comments
theysaidso_admin_options
db_upgraded

Browser metrics Passed 4 tests

An overview of browser requirements for Alley Elementor Widget
This plugin renders optimally with no browser resource issues detected
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,818 ▲8313.37 ▼0.931.62 ▼0.1839.76 ▼5.93
Dashboard /wp-admin2,227 ▲364.84 ▼0.23107.53 ▲1.9838.30 ▼8.29
Posts /wp-admin/edit.php2,109 ▲202.03 ▲0.0140.17 ▲4.3137.16 ▲5.88
Add New Post /wp-admin/post-new.php1,555 ▲4123.31 ▲5.86636.88 ▼57.3952.30 ▲2.33
Media Library /wp-admin/upload.php1,406 ▲184.23 ▲0.0297.40 ▼13.3041.23 ▼6.84

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

🔸 Tests weight: 35 | Verifying that this plugin uninstalls completely without leaving any traces
The following items require your attention
  • Zombie WordPress options were found after uninstall: 6 options
    • widget_theysaidso_widget
    • can_compress_scripts
    • theysaidso_admin_options
    • widget_recent-posts
    • db_upgraded
    • widget_recent-comments

Smoke tests 75% from 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | A shallow check that no server-side errors were triggered
Even though everything seems fine, this is not 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
Almost there! Just fix the following items
  • 30× PHP files trigger errors when accessed directly with GET requests (only 10 are shown):
    • > PHP Notice
      Trying to access array offset on value of type null in wp-content/plugins/alley-elementor-widget/frontend/layouts/price-table/pricingtable-layout.php on line 26
    • > PHP Notice
      Undefined variable: settings in wp-content/plugins/alley-elementor-widget/frontend/layouts/price-table/pricingtable-layout.php on line 19
    • > PHP Notice
      Undefined variable: settings in wp-content/plugins/alley-elementor-widget/frontend/layouts/price-table/pricingtable-layout.php on line 3
    • > PHP Notice
      Undefined variable: settings in wp-content/plugins/alley-elementor-widget/frontend/layouts/price-table/pricingtable-layout.php on line 28
    • > PHP Notice
      Undefined variable: settings in wp-content/plugins/alley-elementor-widget/frontend/layouts/price-table/pricingtable-layout.php on line 35
    • > PHP Fatal error
      Uncaught Error: Call to a member function have_posts() on null in wp-content/plugins/alley-elementor-widget/frontend/layouts/promotion-layout.php:3
    • > PHP Notice
      Trying to access array offset on value of type null in wp-content/plugins/alley-elementor-widget/frontend/layouts/price-table/pricingtable-layout.php on line 77
    • > PHP Notice
      Trying to access array offset on value of type null in wp-content/plugins/alley-elementor-widget/frontend/layouts/price-table/pricingtable-layout.php on line 123
    • > PHP Fatal error
      Uncaught Error: Call to a member function have_posts() on null in wp-content/plugins/alley-elementor-widget/frontend/layouts/service-layout.php:4
    • > PHP Notice
      Undefined variable: all_posts in wp-content/plugins/alley-elementor-widget/frontend/layouts/service-layout.php on line 4

User-side errors Passed 1 test

🔹 Test weight: 20 | Just a short smoke test targeting errors on the browser (console and network errors and warnings)
Everything seems fine, but this is not an exhaustive test

Optimizations

Plugin configuration Passed 29 tests

readme.txt Passed 16 tests

The readme.txt file is important because it is parsed by WordPress.org for the public listing of your plugin
5 plugin tags: blog, elementor, grid, business, contact

alley-elementor-widget/alley-elementor-widget.php Passed 13 tests

The primary PHP file in "Alley Elementor Widget" version 1.0.7 is used by WordPress to initiate all plugin functionality
32 characters long description:
Alley Elementor Widget for HVAC.

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
No dangerous file extensions were detected5,236 lines of code in 22 files:
LanguageFilesBlank linesComment linesLines of code
PHP156686004,853
CSS34916314
JavaScript473869

PHP code Passed 2 tests

A short review of cyclomatic complexity and code structure
There are no cyclomatic complexity problems detected for this plugin
Cyclomatic complexity
Average complexity per logical line of code0.13
Average class complexity7.33
▷ Minimum class complexity1.00
▷ Maximum class complexity21.00
Average method complexity1.51
▷ Minimum method complexity1.00
▷ Maximum method complexity7.00
Code structure
Namespaces7
Interfaces0
Traits2
Classes7
▷ Abstract classes00.00%
▷ Concrete classes7100.00%
▷ Final classes114.29%
Methods112
▷ Static methods10.89%
▷ Public methods3733.04%
▷ Protected methods2017.86%
▷ Private methods5549.11%
Functions0
▷ Named functions00.00%
▷ Anonymous functions00.00%
Constants5
▷ Global constants240.00%
▷ Class constants360.00%
▷ Public constants3100.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 files were detected