90% pilvi-embed

Code Review | Pilvi Embed

WordPress plugin Pilvi Embed scored90%from 54 tests.

About plugin

  • Plugin page: pilvi-embed
  • Plugin version: 1.0.8
  • PHP version: 7.4.16
  • WordPress compatibility: 4.7.3-4.7.3
  • WordPress version: 6.3.1
  • First release: May 9, 2017
  • Latest release: Sep 5, 2017
  • Number of updates: 16
  • Update frequency: every 7.5 days
  • Top authors: pilvi (100%)

Code review

54 tests

User reviews

1 review

Install metrics

10+ active /761 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.13MB] [CPU: ▼23.31ms] Passed 4 tests

Analyzing server-side resources used by Pilvi Embed
This plugin has minimal impact on server resources
PageMemory (MB)CPU Time (ms)
Home /3.53 ▲0.0723.94 ▼19.70
Dashboard /wp-admin3.21 ▼0.1029.30 ▼22.89
Posts /wp-admin/edit.php3.28 ▼0.0837.82 ▼15.51
Add New Post /wp-admin/post-new.php5.53 ▼0.3668.09 ▼35.14
Media Library /wp-admin/upload.php3.23 ▼0.0029.42 ▼8.33

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

Filesystem and database footprint
The plugin installed successfully
Filesystem: 30 new files
Database: no new tables, 14 new options
New WordPress options
pilvi_emb_version
widget_recent-comments
pilvi_emb_language
widget_theysaidso_widget
widget_recent-posts
theysaidso_admin_options
pilvi_embed_plugin_version
pilvi_emb_api_host
pilvi_emb_prices
pilvi_emb_compare
...

Browser metrics Passed 4 tests

An overview of browser requirements for Pilvi Embed
Normal browser usage
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,962 ▲21613.72 ▼0.665.61 ▲3.7640.18 ▼4.94
Dashboard /wp-admin2,216 ▲255.83 ▼0.07105.08 ▲4.3780.76 ▲36.81
Posts /wp-admin/edit.php2,111 ▲191.98 ▼0.0838.59 ▼9.7635.32 ▼5.71
Add New Post /wp-admin/post-new.php1,553 ▲2423.29 ▲4.85769.66 ▲118.3659.97 ▲6.11
Media Library /wp-admin/upload.php1,401 ▲134.22 ▼0.0399.32 ▼3.2583.69 ▲39.23

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

🔸 Tests weight: 35 | Checking the uninstaller removed all traces of the plugin
These items require your attention
  • This plugin does not fully uninstall, leaving 6 options in the database
    • db_upgraded
    • can_compress_scripts
    • widget_theysaidso_widget
    • widget_recent-posts
    • widget_recent-comments
    • theysaidso_admin_options

Smoke tests Passed 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | This is a shallow check 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 | Just a short smoke test targeting errors on the browser (console and network errors and warnings)
No browser issues were found

Optimizations

Plugin configuration Passed 29 tests

readme.txt Passed 16 tests

The readme.txt file uses markdown syntax to describe your plugin to the world
2 plugin tags: pilvi, embed

pilvi-embed/pilvi-embed.php Passed 13 tests

The main file in "Pilvi Embed" v. 1.0.8 serves as a complement to information provided in readme.txt and as the entry point to the plugin
16 characters long description:
Shortcode plugin

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | This is an overview of programming languages used in this plugin; dangerous file extensions are not allowed
No dangerous file extensions were detected1,141 lines of code in 22 files:
LanguageFilesBlank linesComment linesLines of code
PHP17273580727
CSS2264231
JavaScript34717183

PHP code Passed 2 tests

Analyzing logical lines of code, cyclomatic complexity, and other code metrics
This plugin has no cyclomatic complexity issues
Cyclomatic complexity
Average complexity per logical line of code0.29
Average class complexity3.29
▷ Minimum class complexity1.00
▷ Maximum class complexity14.00
Average method complexity1.50
▷ Minimum method complexity1.00
▷ Maximum method complexity13.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes7
▷ Abstract classes00.00%
▷ Concrete classes7100.00%
▷ Final classes00.00%
Methods34
▷ Static methods25.88%
▷ Public methods2985.29%
▷ Protected methods00.00%
▷ Private methods514.71%
Functions4
▷ Named functions4100.00%
▷ Anonymous functions00.00%
Constants1
▷ Global constants1100.00%
▷ Class constants00.00%
▷ Public constants00.00%

Plugin size Passed 2 tests

Image compression Passed 2 tests

All PNG images should be compressed to minimize bandwidth usage for end users
3 PNG files occupy 0.06MB with 0.01MB in potential savings
Potential savings
Compression of 3 random PNG files using pngquant
FileSize - originalSize - compressedSavings
screenshots/pilvi-embed.png56.30KB26.86KB▼ 52.29%
images/pilvi-logo-big.png2.73KB2.72KB0.21%
images/icon.png0.56KB0.56KB0.00%