90% easy-post-embed-code

Code Review | Easy Post Embed Code

WordPress plugin Easy Post Embed Code scored90%from 54 tests.

About plugin

  • Plugin page: easy-post-embed-code
  • Plugin version: 1.1.1
  • PHP version: 7.4.16
  • WordPress compatibility: 4.4-5.0
  • WordPress version: 6.3.1
  • First release: Nov 3, 2015
  • Latest release: Dec 10, 2018
  • Number of updates: 11
  • Update frequency: every 103.0 days
  • Top authors: hlashbrooke (100%)

Code review

54 tests

User reviews

2 reviews

Install metrics

50+ active /3,806 total downloads

Benchmarks

Plugin footprint 83% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | All plugins must install correctly, without throwing any errors, warnings, or notices
Install script ran successfully

Server metrics [RAM: ▲0.06MB] [CPU: ▼2.06ms] Passed 4 tests

This is a short check of server-side resources used by Easy Post Embed Code
This plugin has minimal impact on server resources
PageMemory (MB)CPU Time (ms)
Home /3.53 ▲0.0733.80 ▼7.79
Dashboard /wp-admin3.36 ▲0.0649.34 ▲3.85
Posts /wp-admin/edit.php3.41 ▲0.0646.97 ▲5.67
Add New Post /wp-admin/post-new.php5.96 ▲0.0781.49 ▼7.35
Media Library /wp-admin/upload.php3.29 ▲0.0635.61 ▲3.07

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

A short overview of filesystem and database impact
This plugin was installed successfully
Filesystem: 9 new files
Database: no new tables, 7 new options
New WordPress options
theysaidso_admin_options
can_compress_scripts
widget_theysaidso_widget
db_upgraded
widget_recent-posts
widget_recent-comments
easy_post_embed_code_version

Browser metrics Passed 4 tests

A check of browser resources used by Easy Post Embed Code
This plugin has a minimal impact on browser resources
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,907 ▲16113.89 ▼0.778.77 ▲6.9740.02 ▼2.75
Dashboard /wp-admin2,202 ▲255.64 ▲0.1286.61 ▼13.7736.94 ▼7.79
Posts /wp-admin/edit.php2,110 ▲72.01 ▲0.0241.08 ▲1.1335.76 ▼0.94
Add New Post /wp-admin/post-new.php6,369 ▲4,83227.72 ▲9.68911.27 ▲309.1838.06 ▼29.63
Media Library /wp-admin/upload.php1,410 ▲134.23 ▲0.0295.16 ▼3.5542.31 ▼0.78

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
Please fix the following items
  • The uninstall procedure has failed, leaving 7 options in the database
    • widget_theysaidso_widget
    • easy_post_embed_code_version
    • db_upgraded
    • theysaidso_admin_options
    • can_compress_scripts
    • widget_recent-comments
    • widget_recent-posts

Smoke tests Passed 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 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
No browser errors were detected

Optimizations

Plugin configuration Passed 29 tests

readme.txt Passed 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
7 plugin tags: copy, code, gutenberg, block, post...

easy-post-embed-code/easy-post-embed-code.php Passed 13 tests

This is the main PHP file of "Easy Post Embed Code" version 1.1.1, providing information about the plugin in the header fields and serving as the principal entry point to the plugin's functions
69 characters long description:
Adds each post's embed code to the post edit screen for easy copying.

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | A short review of files and their extensions; it is not recommended to include executable files
There were no executable files found in this plugin235 lines of code in 7 files:
LanguageFilesBlank linesComment linesLines of code
PHP362141164
JavaScript29055
CSS20016

PHP code Passed 2 tests

This plugin's cyclomatic complexity and code structure detailed below
This plugin has no cyclomatic complexity issues
Cyclomatic complexity
Average complexity per logical line of code0.21
Average class complexity17.00
▷ Minimum class complexity17.00
▷ Maximum class complexity17.00
Average method complexity2.14
▷ Minimum method complexity1.00
▷ Maximum method complexity6.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes1
▷ Abstract classes00.00%
▷ Concrete classes1100.00%
▷ Final classes00.00%
Methods14
▷ Static methods17.14%
▷ Public methods1392.86%
▷ Protected methods00.00%
▷ Private methods17.14%
Functions1
▷ Named functions1100.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