84% laravel-paste-embed

Code Review | Laravel-Paste-Embed

WordPress plugin Laravel-Paste-Embed scored84%from 54 tests.

About plugin

  • Plugin page: laravel-paste-embed
  • Plugin version: 1.4
  • PHP version: 7.4.16
  • WordPress compatibility: 3.3-4.0.1
  • WordPress version: 6.3.1
  • First release: Dec 19, 2013
  • Latest release: Nov 30, 2014
  • Number of updates: 15
  • Update frequency: every 40.4 days
  • Top authors: rydurham (100%)

Code review

54 tests

User reviews

1 review

Install metrics

10+ active /896 total downloads

Benchmarks

Plugin footprint 83% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | Verifying that this plugin installs correctly without errors
The plugin installed gracefully, with no errors

Server metrics [RAM: ▲0.02MB] [CPU: ▼3.14ms] Passed 4 tests

Server-side resources used by Laravel-Paste-Embed
This plugin has minimal impact on server resources
PageMemory (MB)CPU Time (ms)
Home /3.48 ▲0.0240.94 ▼2.83
Dashboard /wp-admin3.32 ▲0.0246.64 ▼5.23
Posts /wp-admin/edit.php3.37 ▲0.0246.46 ▼2.81
Add New Post /wp-admin/post-new.php5.90 ▲0.0292.96 ▲6.08
Media Library /wp-admin/upload.php3.24 ▲0.0235.95 ▼1.70

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

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

Browser metrics Passed 4 tests

An overview of browser requirements for Laravel-Paste-Embed
This plugin has a minimal impact on browser resources
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,800 ▲6513.35 ▼0.941.56 ▼0.5439.94 ▼7.31
Dashboard /wp-admin2,206 ▲274.84 ▼1.04106.34 ▲5.4537.53 ▼3.02
Posts /wp-admin/edit.php2,089 ▼02.05 ▼0.0141.70 ▲0.8835.42 ▼1.92
Add New Post /wp-admin/post-new.php1,533 ▲1423.04 ▼0.33667.37 ▼46.9658.77 ▲5.40
Media Library /wp-admin/upload.php1,388 ▲64.25 ▼0.0594.70 ▼22.4643.47 ▼7.17

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

🔸 Tests weight: 35 | All plugins must uninstall correctly, removing their source code and extra database tables they might have created
These items require your attention
  • Zombie WordPress options were found after uninstall: 6 options
    • can_compress_scripts
    • widget_theysaidso_widget
    • widget_recent-comments
    • db_upgraded
    • theysaidso_admin_options
    • widget_recent-posts

Smoke tests 75% from 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | A shallow check that no server-side errors were triggered
Good news, no errors were detected

SRP 50% 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
Please take a closer look at the following
  • 2× GET requests to PHP files trigger server-side errors or Error 500 responses:
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_shortcode() in wp-content/plugins/laravel-paste-embed/laravel-paste-embed.php:83
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_shortcode() in wp-content/plugins/laravel-paste-embed/trunk/laravel-paste-embed.php:83

User-side errors Passed 1 test

🔹 Test weight: 20 | A shallow check that no browser errors were triggered
No browser errors were detected

Optimizations

Plugin configuration Passed 29 tests

readme.txt Passed 16 tests

Don't ignore readme.txt as it is the file that instructs WordPress.org on how to present your plugin to the world
4 plugin tags: paste, laravel, laravelio, bin

laravel-paste-embed/laravel-paste-embed.php Passed 13 tests

"Laravel-Paste-Embed" version 1.4's main PHP file describes plugin functionality and also serves as the entry point to any WordPress functionality
77 characters long description:
A plugin to embed pages & snippets from laravel.io/bin into a wordpress site.

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
Success! There were no dangerous files found in this plugin188 lines of code in 4 files:
LanguageFilesBlank linesComment linesLines of code
CSS115271
PHP1254668
JavaScript10129
Markdown111020

PHP code Passed 2 tests

An short overview of logical lines of code, cyclomatic complexity, and other code metrics
Although this was not an exhaustive test, there were no cyclomatic complexity issues detected
Cyclomatic complexity
Average complexity per logical line of code0.26
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%
Functions10
▷ Named functions10100.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
No PNG images were found in this plugin