79% sj-elementor-addon

Code Review | SJ Elementor Addon

WordPress plugin SJ Elementor Addon scored79%from 54 tests.

About plugin

  • Plugin page: sj-elementor-addon
  • Plugin version: 0.2.0
  • PHP version: 7.4.16
  • WordPress compatibility: 4.0.0-4.7.3
  • WordPress version: 6.3.1
  • First release: Feb 2, 2017
  • Latest release: Apr 10, 2017
  • Number of updates: 10
  • Update frequency: every 6.5 days
  • Top authors: sandesh055 (100%)

Code review

54 tests

User reviews

5 reviews

Install metrics

400+ active /15,507 total downloads

Benchmarks

Plugin footprint 83% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | It is important to correctly install your plugin, without throwing errors or notices
The plugin installed gracefully, with no errors

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

A check of server-side resources used by SJ Elementor Addon
Server-side resource usage in normal parameters
PageMemory (MB)CPU Time (ms)
Home /3.52 ▲0.0140.18 ▼3.57
Dashboard /wp-admin3.36 ▼0.0351.44 ▼15.68
Posts /wp-admin/edit.php3.41 ▲0.0148.12 ▼1.29
Add New Post /wp-admin/post-new.php5.94 ▲0.0182.92 ▼12.49
Media Library /wp-admin/upload.php3.28 ▲0.0137.36 ▲0.84

Server storage [IO: ▲0.35MB] [DB: ▲0.07MB] Passed 3 tests

A short overview of filesystem and database impact
The plugin installed successfully
Filesystem: 45 new files
Database: no new tables, 6 new options
New WordPress options
db_upgraded
theysaidso_admin_options
can_compress_scripts
widget_recent-comments
widget_recent-posts
widget_theysaidso_widget

Browser metrics Passed 4 tests

This is an overview of browser requirements for SJ Elementor Addon
Normal browser usage
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,792 ▲4614.28 ▲0.031.94 ▼0.2044.86 ▲1.53
Dashboard /wp-admin2,198 ▲185.65 ▼0.0395.03 ▲4.5744.24 ▲3.05
Posts /wp-admin/edit.php2,103 ▲32.12 ▲0.1134.04 ▼2.4235.69 ▼0.52
Add New Post /wp-admin/post-new.php1,529 ▲323.14 ▼0.28685.65 ▲35.1363.63 ▲10.61
Media Library /wp-admin/upload.php1,403 ▲34.29 ▲0.09108.72 ▲1.2346.27 ▲3.35

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

🔸 Tests weight: 35 | The uninstall procedure must remove all plugin files and extra database tables
You still need to fix the following
  • Zombie WordPress options detected upon uninstall: 6 options
    • widget_recent-comments
    • can_compress_scripts
    • theysaidso_admin_options
    • widget_theysaidso_widget
    • db_upgraded
    • widget_recent-posts

Smoke tests 50% from 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | A smoke test targeting server-side errors
Even though no errors were found, this is by no means an exhaustive test

SRP 0% from 2 tests

🔹 Tests weight: 20 | SRP (Single-Responsibility Principle) - PHP files must act as libraries and never output text or perform any action when accessed directly in a browser
Please fix the following items
  • 3× GET requests to PHP files return non-empty strings:
    • > /wp-content/plugins/sj-elementor-addon/modules/sjea-row-separator/includes/frontend.php
    • > /wp-content/plugins/sj-elementor-addon/classes/class-sj-ea-admin-settings.php
    • > /wp-content/plugins/sj-elementor-addon/modules/sjea-image-separator/includes/frontend.css.php
  • 32× GET requests to PHP files have triggered server-side errors or warnings (only 10 are shown):
    • > PHP Fatal error
      Uncaught Error: Call to undefined function Elementor\\add_action() in wp-content/plugins/sj-elementor-addon/classes/class-sj-ea-module-scripts.php:15
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_action() in wp-content/plugins/sj-elementor-addon/classes/class-sj-ea-loader.php:21
    • > PHP Notice
      Trying to access array offset on value of type null in wp-content/plugins/sj-elementor-addon/modules/sjea-row-separator/includes/frontend.php on line 4
    • > PHP Notice
      Trying to access array offset on value of type null in wp-content/plugins/sj-elementor-addon/modules/sjea-row-separator/includes/frontend.php on line 8
    • > PHP Notice
      Undefined variable: settings in wp-content/plugins/sj-elementor-addon/modules/sjea-image-separator/includes/frontend.css.php on line 2
    • > PHP Notice
      Undefined variable: settings in wp-content/plugins/sj-elementor-addon/modules/sjea-image-separator/includes/frontend.css.php on line 20
    • > PHP Notice
      Undefined variable: settings in wp-content/plugins/sj-elementor-addon/modules/sjea-row-separator/includes/frontend.php on line 6
    • > PHP Fatal error
      Uncaught Error: Class 'SJEaAdminSettings' not found in wp-content/plugins/sj-elementor-addon/admin/view-connection.php:10
    • > PHP Notice
      Trying to access array offset on value of type null in wp-content/plugins/sj-elementor-addon/modules/sjea-image-separator/includes/frontend.css.php on line 13
    • > PHP Notice
      Undefined variable: settings in wp-content/plugins/sj-elementor-addon/modules/sjea-row-separator/includes/frontend.php on line 7

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)
No browser errors were detected

Optimizations

Plugin configuration Passed 29 tests

readme.txt Passed 16 tests

Often overlooked, readme.txt is one of the most important files in your plugin
5 plugin tags: elementor page builder, elementor addon, svg separator, row separator, subscribe form

sj-elementor-addon/sj-elementor-addon.php Passed 13 tests

The entry point to "SJ Elementor Addon" version 0.2.0 is a PHP file that has certain tags in its header comment area
38 characters long description:
SJ Elementor Addon is elementor addon.

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | An overview of files in this plugin; executable files are not allowed
Everything looks great! No dangerous files found in this plugin5,043 lines of code in 42 files:
LanguageFilesBlank linesComment linesLines of code
PHP359362,8793,980
CSS410050631
JavaScript3135167432

PHP code Passed 2 tests

A short review of cyclomatic complexity and code structure
No cyclomatic complexity issues were detected for this plugin
Cyclomatic complexity
Average complexity per logical line of code0.22
Average class complexity2.76
▷ Minimum class complexity1.00
▷ Maximum class complexity43.00
Average method complexity1.89
▷ Minimum method complexity1.00
▷ Maximum method complexity23.00
Code structure
Namespaces1
Interfaces0
Traits0
Classes123
▷ Abstract classes10.81%
▷ Concrete classes12299.19%
▷ Final classes86.56%
Methods248
▷ Static methods6325.40%
▷ Public methods22691.13%
▷ Protected methods72.82%
▷ Private methods156.05%
Functions0
▷ Named functions00.00%
▷ Anonymous functions00.00%
Constants12
▷ Global constants758.33%
▷ Class constants541.67%
▷ Public constants5100.00%

Plugin size Passed 2 tests

Image compression Passed 2 tests

Often times overlooked, PNG files can occupy unnecessary space in your plugin
No PNG files were detected