68% enjoy-instagram-instagram-responsive-images-gallery-and-carousel

Code Review | Enjoy Social Feed plugin for WordPress website

WordPress plugin Enjoy Social Feed plugin for WordPress website scored68%from 54 tests.

About plugin

  • Plugin page: enjoy-instagram-i...
  • Plugin version: 6.2.2
  • PHP compatiblity: 7.2+
  • PHP version: 7.4.16
  • WordPress compatibility: 4.0-6.0
  • WordPress version: 6.3.1
  • First release: Mar 27, 2014
  • Latest release: May 6, 2022
  • Number of updates: 199
  • Update frequency: every 14.9 days
  • Top authors: mediabeta (64.82%)designemotions (35.68%)

Code review

54 tests

User reviews

103 reviews

Install metrics

10,000+ active /499,927 total downloads

Benchmarks

Plugin footprint 65% from 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.48MB] [CPU: ▲0.06ms] Passed 4 tests

A check of server-side resources used by Enjoy Social Feed plugin for WordPress website
This plugin has minimal impact on server resources
PageMemory (MB)CPU Time (ms)
Home /3.93 ▲0.4743.13 ▲6.20
Dashboard /wp-admin3.85 ▲0.5053.95 ▼2.91
Posts /wp-admin/edit.php3.90 ▲0.5448.02 ▲2.34
Add New Post /wp-admin/post-new.php6.38 ▲0.4985.15 ▼2.38
Media Library /wp-admin/upload.php3.71 ▲0.4737.17 ▲3.17

Server storage [IO: ▲4.89MB] [DB: ▲0.01MB] Passed 3 tests

How much does this plugin use your filesystem and database?
This plugin installed successfully
Filesystem: 106 new files
Database: 2 new tables, 95 new options
New tables
wp_enjoy_instagram_hashtags
wp_enjoy_instagram_media
New WordPress options
enjoyinstagram_grid_link_default
enjoyinstagram_grid_cols_600px_default
enjoyinstagram_grid_cols_768px_default
enjoyinstagram_carousel_theme
enjoyinstagram_lightbox_caption_default
enjoyinstagram_album_delay_default
enjoyinstagram_carousel_margin_default
widget_recent-posts
enjoyinstagram_grid_cols_1024px_default
enjoyinstagram_carousel_items_number
...

Browser metrics Passed 4 tests

An overview of browser requirements for Enjoy Social Feed plugin for WordPress website
Normal browser usage
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,920 ▲13414.18 ▼0.472.51 ▲0.6543.35 ▲1.55
Dashboard /wp-admin2,326 ▲1465.62 ▲0.0590.31 ▲1.6681.64 ▲40.70
Posts /wp-admin/edit.php2,133 ▲332.05 ▲0.0640.61 ▼3.5640.49 ▲4.70
Add New Post /wp-admin/post-new.php1,544 ▲1622.92 ▼0.20663.33 ▼30.8454.25 ▼2.48
Media Library /wp-admin/upload.php1,429 ▲294.19 ▼0.0195.02 ▼14.2442.09 ▼5.79

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

🔸 Tests weight: 35 | The uninstall procedure must remove all plugin files and extra database tables
It is recommended to fix the following
  • Zombie tables were found after uninstall: 2 tables
    • wp_enjoy_instagram_hashtags
    • wp_enjoy_instagram_media
  • This plugin does not fully uninstall, leaving 95 options in the database
    • enjoyinstagram_polaroid_link_altro_default
    • enjoyinstagram_album_link_default
    • enjoyinstagram_carousel_moderate_default
    • enjoyinstagram_carousel_margin_default
    • enjoyinstagram_polaroid_moderate_default
    • enjoyinstagram_grid_step_default
    • enjoyinstagram_album_margin_default
    • enjoyinstagram_album_animation_out_default
    • enjoyinstagram_carousel_autoreload_value_default
    • enjoyinstagram_grid_margin_default
    • ...

Smoke tests 50% from 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | A smoke test targeting server-side errors
The smoke test was a success, however most plugin functionality was not tested

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
The following issues need your attention
  • 1× GET requests to PHP files return non-empty strings:
    • > /wp-content/plugins/enjoy-instagram-instagram-responsive-images-gallery-and-carousel/templates/shortcodes/lightbox-styles/igvertical.php
  • 10× GET requests to PHP files trigger server-side errors or Error 500 responses:
    • > PHP Fatal error
      Uncaught Error: Call to undefined function enjoyinstagram() in wp-content/plugins/enjoy-instagram-instagram-responsive-images-gallery-and-carousel/templates/admin/shortcodes/carousel.php:14
    • > PHP Warning
      Invalid argument supplied for foreach() in wp-content/plugins/enjoy-instagram-instagram-responsive-images-gallery-and-carousel/templates/shortcodes/lightbox-styles/igvertical.php on line 15
    • > PHP Notice
      Undefined variable: result in wp-content/plugins/enjoy-instagram-instagram-responsive-images-gallery-and-carousel/templates/shortcodes/lightbox-styles/igvertical.php on line 15
    • > PHP Fatal error
      Uncaught Error: Call to undefined function enjoyinstagram() in wp-content/plugins/enjoy-instagram-instagram-responsive-images-gallery-and-carousel/templates/admin/diagnostic.php:3
    • > PHP Fatal error
      Uncaught Error: Call to undefined function _e() in wp-content/plugins/enjoy-instagram-instagram-responsive-images-gallery-and-carousel/templates/admin/shortcodes/album.php:5
    • > PHP Fatal error
      Uncaught Error: Call to undefined function _e() in wp-content/plugins/enjoy-instagram-instagram-responsive-images-gallery-and-carousel/templates/admin/shortcodes/badge.php:5
    • > PHP Fatal error
      Uncaught Error: Call to undefined function enjoyinstagram() in wp-content/plugins/enjoy-instagram-instagram-responsive-images-gallery-and-carousel/templates/admin/shortcodes/grid.php:14
    • > PHP Fatal error
      Uncaught Error: Call to undefined function apply_filters() in wp-content/plugins/enjoy-instagram-instagram-responsive-images-gallery-and-carousel/plugin-options/options.php:7
    • > PHP Fatal error
      Uncaught Error: Call to undefined function plugin_dir_url() in wp-content/plugins/enjoy-instagram-instagram-responsive-images-gallery-and-carousel/enjoyinstagram.php:27
    • > PHP Fatal error
      Uncaught Error: Call to undefined function _e() in wp-content/plugins/enjoy-instagram-instagram-responsive-images-gallery-and-carousel/templates/admin/shortcodes/polaroid.php:5

User-side errors Passed 1 test

🔹 Test weight: 20 | This is a smoke test targeting browser errors/issues
Everything seems fine, but this is not an exhaustive test

Optimizations

Plugin configuration 90% from 29 tests

readme.txt 94% 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
Attributes that need to be fixed: Please take inspiration from this readme.txt

enjoy-instagram-instagram-responsive-images-gallery-and-carousel/enjoyinstagram.php 85% from 13 tests

"Enjoy Social Feed plugin for WordPress website" version 6.2.2's primary PHP file adds more information about the plugin and serves as the entry point for WordPress
You should first fix the following items:
  • Main file name: The principal plugin file should be the same as the plugin slug ("enjoy-instagram-instagram-responsive-images-gallery-and-carousel.php" instead of "enjoyinstagram.php")
  • Text Domain: You no longer need to specify the text domain since WordPress 4.6; it must be the same as the plugin slug

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 detected18,707 lines of code in 71 files:
LanguageFilesBlank linesComment linesLines of code
JavaScript171,7634108,851
CSS227501295,217
PHP287111,1254,595
XML16125
SVG30019

PHP code Passed 2 tests

This plugin's cyclomatic complexity and code structure detailed below
Everything seems fine, there were no complexity issues found
Cyclomatic complexity
Average complexity per logical line of code0.29
Average class complexity22.82
▷ Minimum class complexity3.00
▷ Maximum class complexity51.00
Average method complexity3.29
▷ Minimum method complexity1.00
▷ Maximum method complexity15.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes11
▷ Abstract classes00.00%
▷ Concrete classes11100.00%
▷ Final classes327.27%
Methods105
▷ Static methods76.67%
▷ Public methods9691.43%
▷ Protected methods32.86%
▷ Private methods65.71%
Functions30
▷ Named functions30100.00%
▷ Anonymous functions00.00%
Constants12
▷ Global constants12100.00%
▷ Class constants00.00%
▷ Public constants00.00%

Plugin size Passed 2 tests

Image compression Passed 2 tests

Often times overlooked, PNG files can occupy unnecessary space in your plugin
19 PNG files occupy 0.17MB with 0.08MB in potential savings
Potential savings
Compression of 5 random PNG files using pngquant
FileSize - originalSize - compressedSavings
assets/images/moderation-panel.png93.71KB43.13KB▼ 53.98%
assets/images/grid-view.png1.01KB0.61KB▼ 39.40%
assets/images/icons.png0.71KB0.43KB▼ 39.64%
assets/images/followme.png7.21KB3.35KB▼ 53.49%
assets/images/users.png12.67KB7.54KB▼ 40.46%