84% jetpack-sharing-butttons-shortcode

Code Review | Sharing buttons shortcode for Jetpack

WordPress plugin Sharing buttons shortcode for Jetpack scored84%from 54 tests.

About plugin

  • Plugin page: jetpack-sharing-b...
  • Plugin version: 1.2.2
  • PHP version: 7.4.16
  • WordPress compatibility: 3.9-6.2
  • WordPress version: 6.3.1
  • First release: Dec 13, 2012
  • Latest release: Mar 20, 2023
  • Number of updates: 27
  • Update frequency: every 138.9 days
  • Top authors: jeherve (100%)

Code review

54 tests

User reviews

15 reviews

Install metrics

1,000+ active /24,659 total downloads

Benchmarks

Plugin footprint 83% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | Checking the installer triggered no errors
Installer ran successfully

Server metrics [RAM: ▲0.00MB] [CPU: ▼4.14ms] Passed 4 tests

A check of server-side resources used by Sharing buttons shortcode for Jetpack
No issues were detected with server-side resource usage
PageMemory (MB)CPU Time (ms)
Home /3.47 ▲0.0141.72 ▲3.57
Dashboard /wp-admin3.31 ▲0.0152.41 ▼4.09
Posts /wp-admin/edit.php3.36 ▲0.0049.53 ▼1.30
Add New Post /wp-admin/post-new.php5.89 ▲0.0086.36 ▼14.72
Media Library /wp-admin/upload.php3.23 ▲0.0036.71 ▲4.74

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

Input-output and database impact of this plugin
No storage issues were detected
Filesystem: 2 new files
Database: no new tables, 6 new options
New WordPress options
widget_theysaidso_widget
widget_recent-posts
theysaidso_admin_options
db_upgraded
can_compress_scripts
widget_recent-comments

Browser metrics Passed 4 tests

Checking browser requirements for Sharing buttons shortcode for Jetpack
Minimal impact on browser resources
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,800 ▲6514.74 ▲0.451.62 ▲0.0343.32 ▲2.10
Dashboard /wp-admin2,206 ▲184.89 ▼0.99110.16 ▲8.6743.56 ▼0.16
Posts /wp-admin/edit.php2,089 ▼31.99 ▼0.0240.81 ▼0.2733.55 ▼2.34
Add New Post /wp-admin/post-new.php1,533 ▲1423.13 ▲0.00698.14 ▲59.1057.34 ▲1.05
Media Library /wp-admin/upload.php1,385 ▼34.16 ▼0.20126.71 ▲25.8549.82 ▲2.84

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

🔸 Tests weight: 35 | It is important to correctly uninstall your plugin, without leaving any traces
These items require your attention
  • Zombie WordPress options were found after uninstall: 6 options
    • widget_recent-comments
    • theysaidso_admin_options
    • widget_theysaidso_widget
    • widget_recent-posts
    • db_upgraded
    • can_compress_scripts

Smoke tests 75% from 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 50% from 2 tests

🔹 Tests weight: 20 | The single-responsibility principle: PHP files have to remain inert when accessed directly, throwing no errors and performing no actions
Please fix the following items
  • 1× PHP files trigger server errors when accessed directly:
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_action() in wp-content/plugins/jetpack-sharing-butttons-shortcode/jp-sd-shortcode.php:29

User-side errors Passed 1 test

🔹 Test weight: 20 | This is a smoke test targeting browser errors/issues
There were no browser issues found

Optimizations

Plugin configuration 93% from 29 tests

readme.txt Passed 16 tests

It's important to format your readme.txt file correctly as it is parsed for the public listing of your plugin
5 plugin tags: wordpresscom, sharedaddy, shortcode, share, jetpack

jetpack-sharing-butttons-shortcode/jp-sd-shortcode.php 85% from 13 tests

"Sharing buttons shortcode for Jetpack" version 1.2.2's main PHP file describes plugin functionality and also serves as the entry point to any WordPress functionality
Please make the necessary changes and fix the following:
  • Text Domain: If you choose to specify the text domain, it must be the same as the plugin slug; optional since WordPress version 4.6
  • Main file name: It is recommended to name the main PHP file as the plugin slug ("jetpack-sharing-butttons-shortcode.php" instead of "jp-sd-shortcode.php")

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
No dangerous file extensions were detected17 lines of code in 1 file:
LanguageFilesBlank linesComment linesLines of code
PHP121017

PHP code Passed 2 tests

A short review of cyclomatic complexity and code structure
Everything seems fine, there were no complexity issues found
Cyclomatic complexity
Average complexity per logical line of code0.80
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%
Functions2
▷ Named functions2100.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