83% filter-for-elementor

Code Review | Filter for Elementor

WordPress plugin Filter for Elementor scored83%from 54 tests.

About plugin

  • Plugin page: filter-for-elementor
  • Plugin version: 1.0.2
  • PHP compatiblity: 7.2+
  • PHP version: 7.4.16
  • WordPress compatibility: 4.9-6.3.2
  • WordPress version: 6.3.1
  • First release: Jun 9, 2021
  • Latest release: Oct 13, 2023
  • Number of updates: 8
  • Update frequency: every 107.1 days
  • Top authors: danielvoelk (100%)

Code review

54 tests

User reviews

6 reviews

Install metrics

400+ active /3,433 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
The plugin installed successfully, without throwing any errors or notices

Server metrics [RAM: ▲0.01MB] [CPU: ▼9.69ms] Passed 4 tests

Analyzing server-side resources used by Filter for Elementor
Normal server usage
PageMemory (MB)CPU Time (ms)
Home /3.48 ▲0.0232.88 ▼10.59
Dashboard /wp-admin3.32 ▲0.0149.20 ▼3.07
Posts /wp-admin/edit.php3.37 ▲0.0150.38 ▲4.30
Add New Post /wp-admin/post-new.php5.90 ▲0.0182.57 ▼24.91
Media Library /wp-admin/upload.php3.24 ▲0.0136.44 ▼0.17

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

Input-output and database impact of this plugin
The plugin installed successfully
Filesystem: 4 new files
Database: no new tables, 6 new options
New WordPress options
can_compress_scripts
widget_recent-comments
widget_theysaidso_widget
theysaidso_admin_options
db_upgraded
widget_recent-posts

Browser metrics Passed 4 tests

This is an overview of browser requirements for Filter for Elementor
This plugin renders optimally with no browser resource issues detected
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,872 ▲11113.46 ▼0.568.40 ▲6.7241.11 ▼1.90
Dashboard /wp-admin2,195 ▲155.62 ▼0.0598.89 ▲4.5342.49 ▼0.92
Posts /wp-admin/edit.php2,103 ▲31.99 ▼0.0140.82 ▲0.9535.40 ▼3.47
Add New Post /wp-admin/post-new.php1,526 ▼023.75 ▲0.45672.47 ▼10.9258.82 ▲7.12
Media Library /wp-admin/upload.php1,397 ▼64.28 ▲0.07103.27 ▲2.7439.77 ▼4.02

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

🔸 Tests weight: 35 | The uninstall procedure must remove all plugin files and extra database tables
Please fix the following items
  • This plugin does not fully uninstall, leaving 6 options in the database
    • theysaidso_admin_options
    • widget_theysaidso_widget
    • widget_recent-posts
    • widget_recent-comments
    • can_compress_scripts
    • db_upgraded

Smoke tests 75% from 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | Just a short smoke test targeting errors on the server (in the Apache logs)
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
  • 1× GET requests to PHP files trigger server-side errors or Error 500 responses:
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_action() in wp-content/plugins/filter-for-elementor/elementorfilter.php:33

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 90% from 29 tests

readme.txt Passed 16 tests

It's important to format your readme.txt file correctly as it is parsed for the public listing of your plugin
4 plugin tags: elementor filter, filterable gallery, elementor, filter

filter-for-elementor/elementorfilter.php 77% from 13 tests

The principal PHP file in "Filter for Elementor" v. 1.0.2 is loaded by WordPress automatically on each request
Please take the time to fix the following:
  • Requires PHP: Required version must match the one declared in readme.txt ("5.6" instead of "7.2")
  • Requires at least: Required version must match the one declared in readme.txt ("4.5" instead of "4.9")
  • Main file name: Name the main plugin file the same as the plugin slug ("filter-for-elementor.php" instead of "elementorfilter.php")

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | A short glimpse at programming languages used with this plugin and a check that no dangerous files are present
No dangerous file extensions were detected272 lines of code in 3 files:
LanguageFilesBlank linesComment linesLines of code
JavaScript19758218
PHP1192729
CSS14125

PHP code Passed 2 tests

This is a very shot review of cyclomatic complexity and code structure
Everything seems fine, there were no complexity issues found
Cyclomatic complexity
Average complexity per logical line of code0.08
Average class complexity2.00
▷ Minimum class complexity2.00
▷ Maximum class complexity2.00
Average method complexity1.25
▷ Minimum method complexity1.00
▷ Maximum method complexity2.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes1
▷ Abstract classes00.00%
▷ Concrete classes1100.00%
▷ Final classes00.00%
Methods4
▷ Static methods00.00%
▷ Public methods4100.00%
▷ Protected methods00.00%
▷ Private methods00.00%
Functions0
▷ Named functions00.00%
▷ Anonymous functions00.00%
Constants0
▷ Global constants00.00%
▷ Class constants00.00%
▷ Public constants00.00%

Plugin size Passed 2 tests

Image compression Passed 2 tests

PNG files should be compressed to save space and minimize bandwidth usage
There are no PNG files in this plugin