89% wp-gist-embed

Code Review | WP Gist Embed

WordPress plugin WP Gist Embed scored89%from 54 tests.

About plugin

  • Plugin page: wp-gist-embed
  • Plugin version: 0.2
  • PHP version: 7.4.16
  • WordPress compatibility: 3.0.1-4.8
  • WordPress version: 6.3.1
  • First release: Jan 11, 2015
  • Latest release: Jun 20, 2017
  • Number of updates: 15
  • Update frequency: every 61.4 days
  • Top authors: imaginarymedia (100%)

Code review

54 tests

User reviews

1 review

Install metrics

10+ active /945 total downloads

Benchmarks

Plugin footprint 83% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | It is important to correctly install your plugin, without throwing errors or notices
The plugin installed gracefully, with no errors

Server metrics [RAM: ▲0.00MB] [CPU: ▼6.90ms] Passed 4 tests

An overview of server-side resources used by WP Gist Embed
Server-side resource usage in normal parameters
PageMemory (MB)CPU Time (ms)
Home /3.47 ▲0.0139.15 ▼1.73
Dashboard /wp-admin3.32 ▼0.0346.56 ▼17.45
Posts /wp-admin/edit.php3.37 ▲0.0141.90 ▼2.07
Add New Post /wp-admin/post-new.php5.92 ▲0.0480.04 ▼6.34
Media Library /wp-admin/upload.php3.24 ▲0.0131.81 ▼1.31

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

A short overview of filesystem and database impact
There were no storage issued detected upon installing this plugin
Filesystem: 5 new files
Database: no new tables, 6 new options
New WordPress options
widget_recent-posts
widget_recent-comments
widget_theysaidso_widget
theysaidso_admin_options
db_upgraded
can_compress_scripts

Browser metrics Passed 4 tests

A check of browser resources used by WP Gist Embed
This plugin has a minimal impact on browser resources
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,789 ▲4314.72 ▲0.191.93 ▲0.2344.53 ▲1.01
Dashboard /wp-admin2,195 ▲155.53 ▼0.0884.55 ▼1.7234.90 ▼4.13
Posts /wp-admin/edit.php2,102 ▲22.00 ▲0.0335.32 ▼2.4633.16 ▼6.51
Add New Post /wp-admin/post-new.php1,528 ▼022.83 ▼0.28673.39 ▼81.8546.24 ▼16.10
Media Library /wp-admin/upload.php1,405 ▲84.17 ▲0.0099.16 ▼12.6840.92 ▼9.04

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

🔸 Tests weight: 35 | It is important to correctly uninstall your plugin, without leaving any traces
You still need to fix the following
  • This plugin did not uninstall successfully, leaving 6 options in the database
    • widget_recent-comments
    • can_compress_scripts
    • widget_theysaidso_widget
    • theysaidso_admin_options
    • widget_recent-posts
    • db_upgraded

Smoke tests Passed 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)
Everything seems fine, however this is by no means an exhaustive test

SRP Passed 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
Looking good! No server-side errors or output on direct access of PHP files

User-side errors Passed 1 test

🔹 Test weight: 20 | A shallow check that no browser errors were triggered
Everything seems fine, but this is not an exhaustive test

Optimizations

Plugin configuration 93% from 29 tests

readme.txt 94% from 16 tests

The readme.txt file describes your plugin functionality and requirements and it is parsed to prepare the your plugin's listing
Attributes that need to be fixed:
  • Plugin Name: Write the name of your plugin instead of "Plugin Name" on the first line ( === wp-gist-embed === )
The official readme.txt might help

wp-gist-embed/embed-gist.php 92% from 13 tests

The primary PHP file in "WP Gist Embed" version 0.2 is used by WordPress to initiate all plugin functionality
Please make the necessary changes and fix the following:
  • Main file name: Please rename the main PHP file in this plugin to the plugin slug ("wp-gist-embed.php" instead of "embed-gist.php")

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | An overview of files in this plugin; executable files are not allowed
No dangerous file extensions were detected91 lines of code in 3 files:
LanguageFilesBlank linesComment linesLines of code
PHP1142746
JavaScript242545

PHP code Passed 2 tests

This plugin's cyclomatic complexity and code structure detailed below
Although this was not an exhaustive test, there were no cyclomatic complexity issues detected
Cyclomatic complexity
Average complexity per logical line of code0.33
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

Often times overlooked, PNG files can occupy unnecessary space in your plugin
1 compressed PNG file occupies 0.00MB
Potential savings
Compression of 1 random PNG file using pngquant
FileSize - originalSize - compressedSavings
mce-button.png0.42KB0.64KB0.00%