87% filterize-gallery

Code Review | Filterize Gallery

WordPress plugin Filterize Gallery scored 87% from 53 tests.

About plugin

  • Plugin page: filterize-gallery
  • Plugin version: 1.0
  • PHP version: 7.4.16
  • WordPress compatibility: 3.2-4.5.3
  • WordPress version: 5.8.1
  • First release: Jul 25, 2016
  • Latest release: Jul 25, 2016
  • Number of updates: 4
  • Update frequency: every 1.0 days
  • Top authors: sunil25393 (100%)

Code review

53 tests

User reviews

1 review

Install metrics

10+ active / 617 total downloads

Benchmarks

Plugin footprint Passed 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | Checking the installer triggered no errors
The plugin installed gracefully, with no errors

Server metrics [RAM: ▲0.15MB] [CPU: ▼270.14ms] Passed 4 tests

An overview of server-side resources used by Filterize Gallery
This plugin has minimal impact on server resources
PageMemory (MB)CPU Time (ms)
Home /2.93 ▲0.2138.20 ▲13.51
Dashboard /wp-admin3.18 ▲0.1347.27 ▲2.12
Posts /wp-admin/edit.php3.23 ▲0.1342.63 ▼1.40
Add New Post /wp-admin/post-new.php5.77 ▲0.3477.48 ▼1,072.51
Media Library /wp-admin/upload.php3.14 ▲0.1330.59 ▼8.77
Add Gallery /wp-admin/post-new.php?post_type=filterizegallery3.1739.42
Galleries List /wp-admin/edit.php?post_type=filterizegallery3.1333.08

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

Filesystem and database footprint
This plugin installed successfully
Filesystem: 338 new files
Database: no new tables, no new options

Browser metrics Passed 4 tests

This is an overview of browser requirements for Filterize Gallery
This plugin has a minimal impact on browser resources
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /3,957 ▲35216.57 ▲1.1215.65 ▲6.7250.65 ▲8.34
Dashboard /wp-admin2,991 ▲1385.96 ▲0.14166.41 ▲31.02103.47 ▲9.34
Posts /wp-admin/edit.php2,741 ▲352.68 ▼0.0163.00 ▲1.0184.78 ▲1.59
Add New Post /wp-admin/post-new.php1,676 ▲2318.71 ▼0.08348.42 ▼14.29106.56 ▼3.76
Media Library /wp-admin/upload.php1,810 ▲415.01 ▲0.01147.85 ▼2.49104.10 ▼15.39
Add Gallery /wp-admin/post-new.php?post_type=filterizegallery2,4813.5499.1379.19
Galleries List /wp-admin/edit.php?post_type=filterizegallery1,4242.6359.5168.38

Uninstaller [IO: ▲0.00MB] [DB: ▲0.00MB] Passed 4 tests

🔸 Tests weight: 35 | Verifying that this plugin uninstalls completely without leaving any traces
Uninstaller ran successfully

Smoke tests 50% 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 0% 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
The following issues need your attention
  • 7× PHP files perform the task of outputting text when accessed with GET requests:
    • > /wp-content/plugins/filterize-gallery/fg_class.php
    • > /wp-content/plugins/filterize-gallery/index.php
    • > /wp-content/plugins/filterize-gallery/include/image_item.php
    • > /wp-content/plugins/filterize-gallery/include/gallery.php
    • > /wp-content/plugins/filterize-gallery/include/multifilter.php
    • > /wp-content/plugins/filterize-gallery/include/filtersearch.php
    • > /wp-content/plugins/filterize-gallery/include/simplefilter.php
  • 27× PHP files trigger server errors when accessed directly (only 10 are shown):
    • > PHP Fatal error
      Uncaught Error: Class 'CMB2_Type_Select' not found in wp-content/plugins/filterize-gallery/cmb2/includes/types/CMB2_Type_Select_Timezone.php:13
    • > PHP Fatal error
      Uncaught Error: Class 'CMB2_Type_Text' not found in wp-content/plugins/filterize-gallery/cmb2/includes/types/CMB2_Type_File_Base.php:13
    • > PHP Fatal error
      Uncaught Error: Class 'CMB2_Type_Radio' not found in wp-content/plugins/filterize-gallery/cmb2/includes/types/CMB2_Type_Multicheck.php:13
    • > PHP Fatal error
      Uncaught Error: Class 'CMB2_Type_Multi_Base' not found in wp-content/plugins/filterize-gallery/cmb2/includes/types/CMB2_Type_Radio.php:13
    • > PHP Fatal error
      Uncaught Error: Class 'CMB2_Type_Base' not found in wp-content/plugins/filterize-gallery/cmb2/includes/types/CMB2_Type_Multi_Base.php:13
    • > PHP Fatal error
      Uncaught Error: Class 'CMB2_Type_Picker_Base' not found in wp-content/plugins/filterize-gallery/cmb2/includes/types/CMB2_Type_Text_Date.php:13
    • > PHP Fatal error
      Uncaught Error: Class 'CMB2_Type_File_Base' not found in wp-content/plugins/filterize-gallery/cmb2/includes/types/CMB2_Type_File_List.php:13
    • > PHP Fatal error
      Uncaught Error: Class 'CMB2_Type_Text' not found in wp-content/plugins/filterize-gallery/cmb2/includes/types/CMB2_Type_Colorpicker.php:13
    • > PHP Fatal error
      Uncaught Error: Class 'CMB2_Type_Base' not found in wp-content/plugins/filterize-gallery/cmb2/includes/types/CMB2_Type_Text.php:13
    • > PHP Fatal error
      Uncaught Error: Class 'CMB2_Type_Multi_Base' not found in wp-content/plugins/filterize-gallery/cmb2/includes/types/CMB2_Type_Taxonomy_Base.php:13

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 on the user side

Optimizations

Plugin configuration 79% from 29 tests

readme.txt 88% 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
Please fix the following attributes:
  • Screenshots: Screenshot #1 (admin screenshot) image not found
  • Donate link: Invalid url: ""
The official readme.txt might help

filterize-gallery/index.php 69% from 13 tests

Analyzing the main PHP file in "Filterize Gallery" version 1.0
The following require your attention:
  • Domain Path: The domain path points to an invalid folder, "/languages/" does not exist
  • Text Domain: The text domain follows the same naming rules as the plugin slug: lowercase characters and dashes
  • Description: Make the plugin description longer than 10 characters (currently 0 characters long)
  • Main file name: Name the main plugin file the same as the plugin slug ("filterize-gallery.php" instead of "index.php")

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | This is a short overview of programming languages used in this plugin, detecting executable files
No dangerous file extensions were detected40,154 lines of code in 189 files:
LanguageFilesBlank linesComment linesLines of code
PO File11912,73116,33829,151
CSS161,0301,0515,423
PHP471,2562,9684,182
JavaScript72274331,398

PHP code Passed 2 tests

An short overview of logical lines of code, cyclomatic complexity, and other code metrics
No cyclomatic complexity issues were detected for this plugin
Cyclomatic complexity
Average complexity per logical line of code0.49
Average class complexity13.91
▷ Minimum class complexity1.00
▷ Maximum class complexity145.00
Average method complexity3.41
▷ Minimum method complexity1.00
▷ Maximum method complexity26.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes57
▷ Abstract classes47.02%
▷ Concrete classes5392.98%
▷ Final classes00.00%
Methods306
▷ Static methods258.17%
▷ Public methods26987.91%
▷ Protected methods3411.11%
▷ Private methods30.98%
Functions23
▷ Named functions23100.00%
▷ Anonymous functions00.00%
Constants11
▷ Global constants981.82%
▷ Class constants218.18%
▷ Public constants2100.00%

Plugin size Passed 1 test

Image compression Passed 1 test

PNG files should be compressed to save space and minimize bandwidth usage
20 compressed PNG files occupy 0.03MB
Potential savings
Compression of 5 random PNG files using pngquant
FileSize - originalSize - compressedSavings
cmb2/images/ui-bg_glass_95_fef1ec_1x400.png0.12KB0.14KB0.00%
cmb2/images/ui-icons_cd0a0a_256x240.png4.27KB4.11KB▼ 3.78%
cmb2/images/ui-bg_glass_65_ffffff_1x400.png0.10KB0.10KB▼ 5.71%
cmb2/images/ui-icons_454545_256x240.png4.27KB4.11KB▼ 3.78%
cmb2/images/ui-bg_flat_0_aaaaaa_40x100.png0.18KB0.08KB▼ 51.67%