72% instant-gzip-compression

Code Review | Instant Gzip Compression

WordPress plugin Instant Gzip Compression scored72%from 54 tests.

About plugin

  • Plugin page: instant-gzip-comp...
  • Plugin version: 2.0
  • PHP version: 7.4.16
  • WordPress compatibility: 4.0-4.6.1
  • WordPress version: 6.3.1
  • First release: Jul 5, 2016
  • Latest release: Oct 14, 2016
  • Number of updates: 12
  • Update frequency: every 8.5 days
  • Top authors: riotweb (100%)

Code review

54 tests

User reviews

3 reviews

Install metrics

600+ active /8,902 total downloads

Benchmarks

Plugin footprint 82% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | The install procedure must perform silently
This plugin's installer ran successfully

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

A check of server-side resources used by Instant Gzip Compression
Normal server usage
PageMemory (MB)CPU Time (ms)
Home /3.48 ▲0.0143.68 ▲2.71
Dashboard /wp-admin3.32 ▲0.0254.29 ▼3.79
Posts /wp-admin/edit.php3.38 ▲0.0151.60 ▼1.88
Add New Post /wp-admin/post-new.php5.90 ▲0.0187.86 ▼15.79
Media Library /wp-admin/upload.php3.25 ▲0.0138.82 ▼0.93
Instant Gzip compression /wp-admin/options-general.php?page=instant_gzip_compression3.2133.39

Server storage [IO: ▲0.01MB] [DB: ▲0.00MB] 67% from 3 tests

How much does this plugin use your filesystem and database?
These are issues you should consider
  • Illegal file modification found: 1 file (2.40KB) outside of "wp-content/plugins/instant-gzip-compression/" and "wp-content/uploads/"
    • (modified) .htaccess
Filesystem: 3 new files
Database: no new tables, 6 new options
New WordPress options
db_upgraded
widget_recent-comments
widget_recent-posts
widget_theysaidso_widget
can_compress_scripts
theysaidso_admin_options

Browser metrics Passed 4 tests

Checking browser requirements for Instant Gzip Compression
Normal browser usage
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,793 ▲3214.28 ▼0.072.16 ▲0.3544.38 ▲0.14
Dashboard /wp-admin2,202 ▲225.61 ▼0.0385.11 ▼3.7740.31 ▼5.18
Posts /wp-admin/edit.php2,104 ▲41.98 ▼0.0736.44 ▼6.1536.23 ▼7.97
Add New Post /wp-admin/post-new.php1,529 ▲323.22 ▲0.18641.34 ▼0.2954.66 ▲4.82
Media Library /wp-admin/upload.php1,401 ▲14.18 ▼0.1798.86 ▼13.3840.84 ▼3.26
Instant Gzip compression /wp-admin/options-general.php?page=instant_gzip_compression8482.8829.3445.79

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

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

Smoke tests 25% from 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | This is a short smoke test looking for server-side errors
Everything seems fine, however this is by no means an exhaustive test

SRP 0% from 2 tests

🔹 Tests weight: 20 | It is important to ensure that your PHP files perform no action when accessed directly, respecting the single-responsibility principle
Please fix the following
  • 1× GET requests to PHP files return non-empty strings:
    • > /wp-content/plugins/instant-gzip-compression/gzip.php
  • 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/instant-gzip-compression/settings.php:2

User-side errors 0% from 1 test

🔹 Test weight: 20 | This is a smoke test targeting browser errors/issues
Please fix the following browser errors
    • > GET request to /wp-admin/options-general.php?page=instant_gzip_compression
    • > Other (warning) in unknown
    https://www.google.com/adsense/domains/caf.js 218 Unrecognized feature: 'attribution-reporting'.

Optimizations

Plugin configuration 96% from 29 tests

readme.txt Passed 16 tests

The readme.txt file describes your plugin functionality and requirements and it is parsed to prepare the your plugin's listing
8 plugin tags: gzip checker, gzip, cache, loadtime, compression...

instant-gzip-compression/gzip.php 92% from 13 tests

The primary PHP file in "Instant Gzip Compression" version 2.0 is used by WordPress to initiate all plugin functionality
Please make the necessary changes and fix the following:
  • Main file name: Even though not officially enforced, the main plugin file should be the same as the plugin slug ("instant-gzip-compression.php" instead of "gzip.php")

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 detected72 lines of code in 2 files:
LanguageFilesBlank linesComment linesLines of code
PHP2161572

PHP code Passed 2 tests

Analyzing cyclomatic complexity and code structure
Everything seems fine, there were no complexity issues found
Cyclomatic complexity
Average complexity per logical line of code0.07
Average class complexity0.00
▷ Minimum class complexity0.00
▷ Maximum class complexity0.00
Average method complexity0.00
▷ Minimum method complexity0.00
▷ Maximum method complexity0.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes0
▷ Abstract classes00.00%
▷ Concrete classes00.00%
▷ Final classes00.00%
Methods0
▷ Static methods00.00%
▷ Public methods00.00%
▷ Protected methods00.00%
▷ Private methods00.00%
Functions6
▷ Named functions6100.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
PNG images were not found in this plugin