100% social-sharing-buttons-and-counters

Code Review | JC Social Sharing

WordPress plugin JC Social Sharing scored 100% from 54 tests.

About plugin

  • Plugin page: social-sharing-bu...
  • Plugin version: 1.2.8
  • PHP version: 7.4.16
  • WordPress compatibility: 4.0-5.9
  • WordPress version: 5.9.2
  • First release: Apr 7, 2017
  • Latest release: Jan 24, 2022
  • Number of updates: 62
  • Update frequency: every 28.3 days
  • Top authors: jcrr (100%)

Code review

54 tests

User reviews

2 reviews

Install metrics

50+ active / 1,514 total downloads

Benchmarks

Plugin footprint Passed 16 tests

Installer Passed 1 test

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

Server metrics [RAM: ▲0.09MB] [CPU: ▼304.71ms] Passed 4 tests

Server-side resources used by JC Social Sharing
Normal server usage
PageMemory (MB)CPU Time (ms)
Home /3.61 ▲0.1053.18 ▼7.30
Dashboard /wp-admin3.53 ▲0.1232.00 ▼0.96
Posts /wp-admin/edit.php3.76 ▲0.1236.49 ▼0.88
Add New Post /wp-admin/post-new.php7.00 ▲0.03104.87 ▼1,209.71
Media Library /wp-admin/upload.php3.41 ▲0.1127.63 ▲0.09
JC Social Sharing /wp-admin/options-general.php?page=social-sharing-buttons-jc3.3825.44

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

A short overview of filesystem and database impact
No storage issues were detected
Filesystem: 14 new files
Database: no new tables, no new options

Browser metrics Passed 4 tests

An overview of browser requirements for JC Social Sharing
There were no issues detected in relation to browser resource usage
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /3,914 ▲16016.19 ▲0.568.79 ▲2.742.55 ▼0.36
Dashboard /wp-admin2,897 ▲366.05 ▼0.14113.58 ▼19.44156.46 ▼1.40
Posts /wp-admin/edit.php2,693 ▲363.24 ▼0.0063.04 ▲0.61139.83 ▲2.92
Add New Post /wp-admin/post-new.php1,699 ▲3821.23 ▲4.86405.74 ▼7.77157.47 ▼4.02
Media Library /wp-admin/upload.php1,706 ▲115.53 ▲0.03143.30 ▲5.98193.92 ▲10.89
JC Social Sharing /wp-admin/options-general.php?page=social-sharing-buttons-jc1,4723.0459.90121.84

Uninstaller [IO: ▲0.00MB] [DB: ▲0.00MB] Passed 4 tests

🔸 Tests weight: 35 | Checking the uninstaller removed all traces of the plugin
Uninstall script ran successfully

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 | The single-responsibility principle: PHP files have to remain inert when accessed directly, throwing no errors and performing no actions
Looking good! No server-side errors or output on direct access of PHP files

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

Often overlooked, readme.txt is one of the most important files in your plugin
7 plugin tags: buttons, share, whatsapp, telegram, twitter...

social-sharing-buttons-and-counters/social-sharing-buttons-and-counters.php 92% from 13 tests

This is the main PHP file of "JC Social Sharing" version 1.2.8, providing information about the plugin in the header fields and serving as the principal entry point to the plugin's functions
Please make the necessary changes and fix the following:
  • Text Domain: The text domain must be the same as the plugin slug, although optional since WordPress version 4.6

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | A short glimpse at programming languages used with this plugin and a check that no dangerous files are present
Good job! No executable or dangerous file extensions detected777 lines of code in 12 files:
LanguageFilesBlank linesComment linesLines of code
PHP78213557
PO File169178137
CSS220056
JavaScript22227

PHP code Passed 2 tests

An overview of cyclomatic complexity and code structure
There were no cyclomatic complexity issued detected
Cyclomatic complexity
Average complexity per logical line of code0.45
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%
Functions22
▷ Named functions2195.45%
▷ Anonymous functions14.55%
Constants3
▷ Global constants3100.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
There are no PNG files in this plugin