74% superb-social-share-and-follow-buttons

Code Review | Superb Social Media Share Buttons and Follow Buttons for WordPress

WordPress plugin Superb Social Media Share Buttons and Follow Buttons for WordPress scored74%from 54 tests.

About plugin

  • Plugin page: superb-social-sha...
  • Plugin version: 1.1.7
  • PHP compatiblity: 5.2.4+
  • PHP version: 7.4.16
  • WordPress compatibility: 3.0.1-6.3
  • WordPress version: 6.3.1
  • First release: Jun 20, 2019
  • Latest release: Sep 25, 2023
  • Number of updates: 39
  • Update frequency: every 40.0 days
  • Top authors: suplugins (100%)

Code review

54 tests

User reviews

10 reviews

Install metrics

10,000+ active /153,715 total downloads

Benchmarks

Plugin footprint 65% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | The install procedure must perform silently
The plugin installed successfully, without throwing any errors or notices

Server metrics [RAM: ▲0.03MB] [CPU: ▼4.26ms] Passed 4 tests

Server-side resources used by Superb Social Media Share Buttons and Follow Buttons for WordPress
This plugin has minimal impact on server resources
PageMemory (MB)CPU Time (ms)
Home /3.49 ▲0.0343.53 ▲1.05
Dashboard /wp-admin3.33 ▲0.0347.31 ▼0.21
Posts /wp-admin/edit.php3.38 ▲0.0349.33 ▼0.47
Add New Post /wp-admin/post-new.php5.91 ▲0.0385.67 ▼16.15
Media Library /wp-admin/upload.php3.26 ▲0.0337.19 ▼0.22
Share Buttons /wp-admin/admin.php?page=spbsm3.2935.32
Follow Buttons /wp-admin/admin.php?page=spbsm-follow3.2835.82

Server storage [IO: ▲2.40MB] [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: 88 new files
Database: 2 new tables, 7 new options
New tables
wp_spbsm
wp_spbsm_position
New WordPress options
theysaidso_admin_options
widget_recent-comments
can_compress_scripts
db_upgraded
spbsm_db_version
widget_recent-posts
widget_theysaidso_widget

Browser metrics Passed 4 tests

This is an overview of browser requirements for Superb Social Media Share Buttons and Follow Buttons for WordPress
This plugin renders optimally with no browser resource issues detected
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,830 ▲8413.22 ▼1.532.11 ▲0.1043.88 ▼1.13
Dashboard /wp-admin2,229 ▲405.83 ▼0.0795.29 ▼13.7285.52 ▲42.30
Posts /wp-admin/edit.php2,121 ▲291.99 ▼0.0338.28 ▲1.8037.80 ▼2.99
Add New Post /wp-admin/post-new.php1,536 ▲1723.12 ▼0.19653.70 ▼12.0355.61 ▼5.55
Media Library /wp-admin/upload.php1,408 ▲204.17 ▼0.03103.46 ▼0.1772.05 ▲25.88
Share Buttons /wp-admin/admin.php?page=spbsm1,2102.2844.49103.58
Follow Buttons /wp-admin/admin.php?page=spbsm-follow1,6532.3240.6458.22

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

🔸 Tests weight: 35 | The uninstall procedure must remove all plugin files and extra database tables
The following items require your attention
  • Zombie tables detected upon uninstall: 2 tables
    • wp_spbsm
    • wp_spbsm_position
  • This plugin did not uninstall successfully, leaving 7 options in the database
    • widget_recent-comments
    • db_upgraded
    • spbsm_db_version
    • widget_theysaidso_widget
    • theysaidso_admin_options
    • widget_recent-posts
    • 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
Good news, no errors were detected

SRP 50% from 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
Please take a closer look at the following
  • 6× GET requests to PHP files trigger server-side errors or Error 500 responses:
    • > PHP Fatal error
      Uncaught Error: Call to undefined function __() in wp-content/plugins/superb-social-share-and-follow-buttons/inc/backend-parts/generalform.php:2
    • > PHP Fatal error
      Uncaught Error: Using $this when not in object context in wp-content/plugins/superb-social-share-and-follow-buttons/inc/backend_follow.php:2
    • > PHP Fatal error
      Uncaught Error: Using $this when not in object context in wp-content/plugins/superb-social-share-and-follow-buttons/inc/backend_share.php:2
    • > PHP Fatal error
      Uncaught Error: Call to undefined function esc_url() in wp-content/plugins/superb-social-share-and-follow-buttons/inc/backend-parts/designform.php:3
    • > PHP Fatal error
      Uncaught Error: Call to undefined function esc_attr__() in wp-content/plugins/superb-social-share-and-follow-buttons/inc/backend-parts/submitbutton.php:2
    • > PHP Fatal error
      Uncaught Error: Call to undefined function esc_url() in wp-content/plugins/superb-social-share-and-follow-buttons/readmorebuttons.php:1

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 96% from 29 tests

readme.txt Passed 16 tests

Perhaps the most important file in your plugin readme.txt gets parsed in order to generate the public listing of your plugin
5 plugin tags: share, buttons, media, follow, social

superb-social-share-and-follow-buttons/superb-social-share-and-follow-buttons.php 92% from 13 tests

The main PHP script in "Superb Social Media Share Buttons and Follow Buttons for WordPress" version 1.1.7 is automatically included on every request by WordPress
Please take the time to fix the following:
  • Text Domain: The text domain is optional since WordPress version 4.6; if you do specify it, it must be the same as the plugin slug

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | Executable files are considered dangerous and should not be included with any WordPress plugin
Success! There were no dangerous files found in this plugin21,270 lines of code in 60 files:
LanguageFilesBlank linesComment linesLines of code
SVG4002517,947
PHP151944141,604
CSS345231,054
JavaScript268143665

PHP code Passed 2 tests

An overview of cyclomatic complexity and code structure
Great job! No cyclomatic complexity issues were detected in this plugin
Cyclomatic complexity
Average complexity per logical line of code0.43
Average class complexity28.00
▷ Minimum class complexity1.00
▷ Maximum class complexity104.00
Average method complexity3.84
▷ Minimum method complexity1.00
▷ Maximum method complexity22.00
Code structure
Namespaces2
Interfaces0
Traits0
Classes7
▷ Abstract classes00.00%
▷ Concrete classes7100.00%
▷ Final classes228.57%
Methods64
▷ Static methods23.12%
▷ Public methods5484.38%
▷ Protected methods11.56%
▷ Private methods914.06%
Functions3
▷ Named functions00.00%
▷ Anonymous functions3100.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
9 PNG files occupy 0.31MB with 0.12MB in potential savings
Potential savings
Compression of 5 random PNG files using pngquant
FileSize - originalSize - compressedSavings
assets/img/icon-discount-15.png3.23KB2.58KB▼ 20.10%
assets/img/60-icon.png6.48KB3.04KB▼ 53.11%
assets/img/design.png46.63KB18.56KB▼ 60.20%
assets/img/banner-772x250.png17.85KB7.40KB▼ 58.55%
assets/img/drag.png0.78KB0.74KB▼ 5.35%