10% filejet-pro

Code Review | FileJet Pro

WordPress plugin FileJet Pro scored10%from 54 tests.

About plugin

  • Plugin page: filejet-pro
  • Plugin version: 1.3.15
  • PHP compatiblity: 5.6+
  • PHP version: 7.4.16
  • WordPress compatibility: 4.0-5.9
  • WordPress version: 6.3.1
  • First release: May 2, 2019
  • Latest release: Jan 31, 2022
  • Number of updates: 35
  • Update frequency: every 28.7 days
  • Top authors: filejet (100%)

Code review

54 tests

User reviews

1 review

Install metrics

10+ active /1,191 total downloads

Benchmarks

Plugin footprint 58% from 16 tests

Installer 0% from 1 test

🔺 Critical test (weight: 50) | Verifying that this plugin installs correctly without errors
It is recommended to fix the following installer errors
  • This plugin did not install gracefully
    • > Warning in wp-content/plugins/filejet-pro/class.filejet.php+244
    array_key_exists() expects parameter 2 to be array, null given

Server metrics [RAM: ▲0.20MB] [CPU: ▼8.15ms] Passed 4 tests

This is a short check of server-side resources used by FileJet Pro
No issues were detected with server-side resource usage
PageMemory (MB)CPU Time (ms)
Home /3.61 ▲0.1546.42 ▲2.54
Dashboard /wp-admin3.57 ▲0.2754.33 ▲0.80
Posts /wp-admin/edit.php3.62 ▲0.2650.37 ▼3.66
Add New Post /wp-admin/post-new.php6.09 ▲0.20100.57 ▼32.29
Media Library /wp-admin/upload.php3.43 ▲0.2043.93 ▲5.46
FileJet Pro /wp-admin/options-general.php?page=filejet-pro/filejet.php3.4136.01

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

Filesystem and database footprint
This plugin was installed successfully
Filesystem: 26 new files
Database: no new tables, 7 new options
New WordPress options
widget_recent-posts
can_compress_scripts
theysaidso_admin_options
widget_recent-comments
filejet_config
db_upgraded
widget_theysaidso_widget

Browser metrics Passed 4 tests

A check of browser resources used by FileJet Pro
Normal browser usage
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,950 ▲17913.78 ▼0.611.80 ▼0.2133.11 ▼14.77
Dashboard /wp-admin2,339 ▲1515.57 ▲0.64119.29 ▲14.9578.69 ▲37.87
Posts /wp-admin/edit.php2,096 ▲41.98 ▼0.0837.48 ▼0.6530.75 ▼7.20
Add New Post /wp-admin/post-new.php1,536 ▲123.37 ▲0.15666.47 ▼28.1653.36 ▼2.15
Media Library /wp-admin/upload.php1,452 ▲674.89 ▲0.68105.45 ▼13.9781.33 ▲30.11
FileJet Pro /wp-admin/options-general.php?page=filejet-pro/filejet.php9062.4629.6329.43

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

🔸 Tests weight: 35 | Checking the uninstaller removed all traces of the plugin
It is recommended to fix the following
  • Zombie WordPress options were found after uninstall: 7 options
    • widget_recent-comments
    • theysaidso_admin_options
    • db_upgraded
    • can_compress_scripts
    • widget_recent-posts
    • widget_theysaidso_widget
    • filejet_config

Smoke tests 50% from 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | This is a short smoke test looking for server-side errors
The smoke test was a success, however most plugin functionality was not tested

SRP 0% from 2 tests

🔹 Tests weight: 20 | A shallow check of the single-responsibility principle; PHP files should perform no action - including output of placeholder text - and trigger no errors when accessed directly
The following issues need your attention
  • 1× GET requests to PHP files return non-empty strings:
    • > /wp-content/plugins/filejet-pro/filejet.php
  • 7× PHP files trigger errors when accessed directly with GET requests:
    • > PHP Fatal error
      Uncaught Error: Class 'Filejet_Admin' not found in wp-content/plugins/filejet-pro/assets/views/widget.php:2
    • > PHP Fatal error
      Uncaught Error: Call to undefined function esc_url() in wp-content/plugins/filejet-pro/assets/views/passback.php:3
    • > PHP Notice
      Undefined variable: type in wp-content/plugins/filejet-pro/assets/views/notice.php on line 23
    • > PHP Notice
      Undefined variable: type in wp-content/plugins/filejet-pro/assets/views/notice.php on line 1
    • > PHP Fatal error
      Uncaught Error: Class 'Filejet_Admin' not found in wp-content/plugins/filejet-pro/assets/views/setup.php:2
    • > PHP Fatal error
      Uncaught Error: Call to undefined function esc_url() in wp-content/plugins/filejet-pro/assets/views/welcome.php:3
    • > PHP Notice
      Undefined variable: type in wp-content/plugins/filejet-pro/assets/views/notice.php on line 19

User-side errors Passed 1 test

🔹 Test weight: 20 | This is a smoke test targeting browser errors/issues
Everything seems fine on the user side

Optimizations

Plugin configuration 93% from 29 tests

readme.txt Passed 16 tests

Perhaps the most important file in your plugin readme.txt gets parsed in order to generate the public listing of your plugin
5 plugin tags: webp, image optimization, smart cdn, convert, filejet

filejet-pro/filejet.php 85% from 13 tests

The main file in "FileJet Pro" v. 1.3.15 serves as a complement to information provided in readme.txt and as the entry point to the plugin
It is important to fix the following:
  • Main file name: The principal plugin file should be the same as the plugin slug ("filejet-pro.php" instead of "filejet.php")
  • Text Domain: The text domain name must use dashes instead of underscores, and it must be lowercase

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | There should be no dangerous file extensions present in any WordPress plugin
Good job! No executable or dangerous file extensions detected2,069 lines of code in 21 files:
LanguageFilesBlank linesComment linesLines of code
PHP11248731,363
Sass1433673
SVG70131
CSS1011
JavaScript1061

PHP code Passed 2 tests

A brief analysis of cyclomatic complexity and code structure for this plugin
There were no cyclomatic complexity issued detected
Cyclomatic complexity
Average complexity per logical line of code0.42
Average class complexity39.75
▷ Minimum class complexity3.00
▷ Maximum class complexity71.00
Average method complexity3.01
▷ Minimum method complexity1.00
▷ Maximum method complexity14.00
Code structure
Namespaces1
Interfaces0
Traits0
Classes4
▷ Abstract classes00.00%
▷ Concrete classes4100.00%
▷ Final classes00.00%
Methods77
▷ Static methods5571.43%
▷ Public methods5976.62%
▷ Protected methods00.00%
▷ Private methods1823.38%
Functions2
▷ Named functions2100.00%
▷ Anonymous functions00.00%
Constants31
▷ Global constants412.90%
▷ Class constants2787.10%
▷ Public constants27100.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
2 PNG files occupy 0.00MB with 0.00MB in potential savings
Potential savings
Compression of 2 random PNG files using pngquant
FileSize - originalSize - compressedSavings
assets/images/filejet-32x32.png0.59KB0.37KB▼ 37.62%
assets/images/filejet-16x16.png0.33KB0.22KB▼ 34.22%