90% embed-privacy

Code Review | Embed Privacy

WordPress plugin Embed Privacy scored90%from 54 tests.

About plugin

  • Plugin page: embed-privacy
  • Plugin version: 1.8.1
  • PHP compatiblity: 5.6+
  • PHP version: 7.4.16
  • WordPress compatibility: 5.9-6.3
  • WordPress version: 6.3.1
  • First release: Oct 4, 2018
  • Latest release: Nov 1, 2023
  • Number of updates: 75
  • Update frequency: every 24.8 days
  • Top authors: epiphyt (100%)

Code review

54 tests

User reviews

18 reviews

Install metrics

10,000+ active /128,233 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.08MB] [CPU: ▼4.73ms] Passed 4 tests

This is a short check of server-side resources used by Embed Privacy
Normal server usage
PageMemory (MB)CPU Time (ms)
Home /3.72 ▲0.2647.39 ▲4.42
Dashboard /wp-admin3.38 ▲0.0449.13 ▼14.76
Posts /wp-admin/edit.php3.49 ▲0.1350.26 ▲3.17
Add New Post /wp-admin/post-new.php5.96 ▲0.0884.73 ▼8.45
Media Library /wp-admin/upload.php3.30 ▲0.0737.35 ▲1.11
Embed Privacy /wp-admin/options-general.php?page=embed_privacy3.2934.75

Server storage [IO: ▲0.39MB] [DB: ▲0.02MB] Passed 3 tests

How much does this plugin use your filesystem and database?
No storage issues were detected
Filesystem: 78 new files
Database: no new tables, 7 new options
New WordPress options
can_compress_scripts
theysaidso_admin_options
widget_theysaidso_widget
embed_privacy_migrate_version
widget_recent-posts
db_upgraded
widget_recent-comments

Browser metrics Passed 4 tests

This is an overview of browser requirements for Embed Privacy
This plugin renders optimally with no browser resource issues detected
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,793 ▲5814.38 ▲0.151.97 ▲0.0644.22 ▼1.45
Dashboard /wp-admin2,202 ▲225.64 ▼0.0088.32 ▼6.9740.76 ▼1.12
Posts /wp-admin/edit.php2,104 ▲42.01 ▲0.0139.76 ▲3.4036.69 ▲1.14
Add New Post /wp-admin/post-new.php1,531 ▼023.23 ▲0.21665.82 ▼37.2044.43 ▼13.13
Media Library /wp-admin/upload.php1,404 ▲74.26 ▲0.0897.54 ▼1.0941.69 ▼8.90
Embed Privacy /wp-admin/options-general.php?page=embed_privacy8412.1224.8625.35

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 detected upon uninstall: 6 options
    • 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 | This is a short smoke test looking for server-side errors
Even though no errors were found, 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
The SRP test was a success

User-side errors Passed 1 test

🔹 Test weight: 20 | This is a shallow check for browser errors
There were no browser issues found

Optimizations

Plugin configuration 96% from 29 tests

readme.txt Passed 16 tests

The readme.txt file uses markdown syntax to describe your plugin to the world
3 plugin tags: privacy, oembed, gutenberg

embed-privacy/embed-privacy.php 92% from 13 tests

This is the main PHP file of "Embed Privacy" version 1.8.1, providing information about the plugin in the header fields and serving as the principal entry point to the plugin's functions
Please take the time to fix the following:
  • Domain Path: The domain path points to a folder that does not exist ("/languages")

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | This is a short overview of programming languages used in this plugin, detecting executable files
There were no executable files found in this plugin4,341 lines of code in 33 files:
LanguageFilesBlank linesComment linesLines of code
PHP86381,3453,234
Markdown51690643
JavaScript681117279
CSS141514185

PHP code Passed 2 tests

Analyzing cyclomatic complexity and code structure
This plugin has no cyclomatic complexity issues
Cyclomatic complexity
Average complexity per logical line of code0.51
Average class complexity84.17
▷ Minimum class complexity6.00
▷ Maximum class complexity285.00
Average method complexity5.25
▷ Minimum method complexity1.00
▷ Maximum method complexity35.00
Code structure
Namespaces1
Interfaces0
Traits0
Classes6
▷ Abstract classes00.00%
▷ Concrete classes6100.00%
▷ Final classes00.00%
Methods107
▷ Static methods65.61%
▷ Public methods7570.09%
▷ Protected methods00.00%
▷ Private methods3229.91%
Functions5
▷ Named functions360.00%
▷ Anonymous functions240.00%
Constants5
▷ Global constants360.00%
▷ Class constants240.00%
▷ Public constants2100.00%

Plugin size Passed 2 tests

Image compression Passed 2 tests

It is recommended to compress PNG files in your plugin to minimize bandwidth usage
41 compressed PNG files occupy 0.13MB
Potential savings
Compression of 5 random PNG files using pngquant
FileSize - originalSize - compressedSavings
assets/images/embed-vimeo.png2.95KB3.17KB0.00%
assets/images/embed-smugmug.png7.12KB5.31KB▼ 25.46%
assets/images/embed-meetup.png2.46KB2.58KB0.00%
assets/images/embed-wolfram-cloud.png3.31KB3.53KB0.00%
assets/images/embed-pinterest.png1.03KB1.08KB0.00%