10% share-block

Code Review | Social Block

WordPress plugin Social Block scored10%from 54 tests.

About plugin

  • Plugin page: share-block
  • Plugin version: 1.0.0
  • PHP version: 7.4.16
  • WordPress compatibility: 4.9.1-4.9.1
  • WordPress version: 6.3.1
  • First release: Jan 9, 2018
  • Latest release: Jan 9, 2018
  • Number of updates: 5
  • Update frequency: every 1.8 days
  • Top authors: Shelob9 (100%)

Code review

54 tests

User reviews

1 review

Install metrics

10+ active /1,600 total downloads

Benchmarks

Plugin footprint 40% from 16 tests

Installer 0% from 1 test

🔺 Critical test (weight: 50) | It is important to correctly install your plugin, without throwing errors or notices
These installer errors require your attention
  • Install procedure validation failed for this plugin
    • > Deprecated in wp-content/plugins/share-block/share-block.php+70
    Unparenthesized `a ? b : c ? d : e` is deprecated. Use either `(a ? b : c) ? d : e` or `a ? b : (c ? d : e)`

Server metrics [RAM: ▼1.91MB] [CPU: ▼52.04ms] Passed 4 tests

A check of server-side resources used by Social Block
Normal server usage
PageMemory (MB)CPU Time (ms)
Home /2.08 ▼1.393.88 ▼39.57
Dashboard /wp-admin2.10 ▼1.217.00 ▼42.46
Posts /wp-admin/edit.php2.10 ▼1.266.53 ▼39.47
Add New Post /wp-admin/post-new.php2.10 ▼3.796.49 ▼86.67
Media Library /wp-admin/upload.php2.10 ▼1.136.27 ▼29.97

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

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

Browser metrics Passed 4 tests

A check of browser resources used by Social Block
Normal browser usage
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,887 ▲14115.82 ▲1.4175.32 ▲73.5538.24 ▲2.12
Dashboard /wp-admin2,209 ▲244.85 ▼1.0097.49 ▼4.2438.50 ▼7.63
Posts /wp-admin/edit.php2,092 ▲31.99 ▼0.0337.18 ▼0.7934.84 ▼0.64
Add New Post /wp-admin/post-new.php6,193 ▲4,66022.42 ▼0.79874.46 ▲181.3845.97 ▼5.36
Media Library /wp-admin/upload.php1,388 ▼34.20 ▼0.0396.31 ▼11.9840.59 ▼8.66

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

🔸 Tests weight: 35 | It is important to correctly uninstall your plugin, without leaving any traces
These items require your attention
  • This plugin cannot be uninstalled
    • > Deprecated in wp-content/plugins/share-block/share-block.php+70
    Unparenthesized `a ? b : c ? d : e` is deprecated. Use either `(a ? b : c) ? d : e` or `a ? b : (c ? d : e)`
  • This plugin did not uninstall successfully, leaving 6 options in the database
    • widget_recent-comments
    • theysaidso_admin_options
    • can_compress_scripts
    • widget_recent-posts
    • widget_theysaidso_widget
    • db_upgraded

Smoke tests Passed 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | A smoke test targeting server-side errors
Good news, no errors were detected

SRP Passed 2 tests

🔹 Tests weight: 20 | It is important to ensure that your PHP files perform no action when accessed directly, respecting the single-responsibility principle
Everything seems fine, however this is by no means an exhaustive test

User-side errors Passed 1 test

🔹 Test weight: 20 | This is just a short smoke test looking for browser issues
There were no browser issues found

Optimizations

Plugin configuration Passed 29 tests

readme.txt Passed 16 tests

The readme.txt file is undoubtedly the most important file in your plugin, preparing it for public listing on WordPress.org
No tags were detected

share-block/share-block.php Passed 13 tests

The primary PHP file in "Social Block" version 1.0.0 is used by WordPress to initiate all plugin functionality
59 characters long description:
Social share block for the WordPress Gutenberg block editor

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | A short check of programming languages and file extensions; no executable files are allowed
There were no executable files found in this plugin24,044 lines of code in 6 files:
LanguageFilesBlank linesComment linesLines of code
JavaScript24,3406,79123,778
PHP13372156
CSS220093
Markdown16017

PHP code Passed 2 tests

This is a short overview of cyclomatic complexity and code structure for this plugin
This plugin has no cyclomatic complexity problems
Cyclomatic complexity
Average complexity per logical line of code0.53
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%
Functions7
▷ Named functions7100.00%
▷ Anonymous functions00.00%
Constants1
▷ Global constants1100.00%
▷ Class constants00.00%
▷ Public constants00.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
PNG images were not found in this plugin