78% bws-linkedin

Code Review | BestWebSoft's LinkedIn

WordPress plugin BestWebSoft's LinkedIn scored78%from 54 tests.

About plugin

  • Plugin page: bws-linkedin
  • Plugin version: 1.1.4
  • PHP version: 7.4.16
  • WordPress compatibility: 5.6-6.2
  • WordPress version: 6.3.1
  • First release: May 10, 2016
  • Latest release: May 22, 2023
  • Number of updates: 29
  • Update frequency: every 88.6 days
  • Top authors: bestwebsoft (100%)

Code review

54 tests

User reviews

5 reviews

Install metrics

400+ active /11,671 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
This plugin's installer ran successfully

Server metrics [RAM: ▲0.80MB] [CPU: ▲3.62ms] Passed 4 tests

Server-side resources used by BestWebSoft's LinkedIn
Server-side resource usage in normal parameters
PageMemory (MB)CPU Time (ms)
Home /4.26 ▲0.8051.44 ▲7.77
Dashboard /wp-admin4.16 ▲0.8557.16 ▲4.28
Posts /wp-admin/edit.php4.21 ▲0.8556.06 ▲3.85
Add New Post /wp-admin/post-new.php6.69 ▲0.8095.40 ▼1.42
Media Library /wp-admin/upload.php4.01 ▲0.7848.06 ▲12.84

Server storage [IO: ▲4.73MB] [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: 121 new files
Database: no new tables, 8 new options
New WordPress options
widget_recent-comments
can_compress_scripts
widget_theysaidso_widget
db_upgraded
lnkdn_options
theysaidso_admin_options
bstwbsftwppdtplgns_options
widget_recent-posts

Browser metrics Passed 4 tests

Checking browser requirements for BestWebSoft's LinkedIn
There were no issues detected in relation to browser resource usage
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,902 ▲14114.64 ▲0.291.80 ▲0.1841.20 ▼3.11
Dashboard /wp-admin2,304 ▲1275.63 ▲0.0589.21 ▼0.0339.67 ▼4.58
Posts /wp-admin/edit.php2,219 ▲1192.21 ▲0.1040.11 ▲3.5935.21 ▼2.99
Add New Post /wp-admin/post-new.php1,636 ▲11023.34 ▲0.27656.44 ▲12.9052.49 ▼3.48
Media Library /wp-admin/upload.php1,506 ▲1064.20 ▲0.0499.12 ▼17.9944.03 ▼3.89
Settings /wp-admin/linkedin.php260.420.1813.64
BWS Panel /wp-admin/linkedin.php?page=lnkdn-bws-panel260.420.096.42

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

🔸 Tests weight: 35 | All plugins must uninstall correctly, removing their source code and extra database tables they might have created
These items require your attention
  • The uninstall procedure has failed, leaving 6 options in the database
    • theysaidso_admin_options
    • can_compress_scripts
    • db_upgraded
    • widget_theysaidso_widget
    • widget_recent-comments
    • widget_recent-posts

Smoke tests 50% from 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | Just a short smoke test targeting errors on the server (in the Apache logs)
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 applies for WordPress plugins as well - please make sure your PHP files perform no actions when accessed directly
The following issues need your attention
  • 4× GET requests to PHP files trigger server-side errors or Error 500 responses:
    • > PHP Fatal error
      Uncaught Error: Class 'Bws_Settings_Tabs' not found in wp-content/plugins/bws-linkedin/includes/class-lnkdn-settings.php:7
    • > PHP Fatal error
      Uncaught Error: Call to undefined function __() in wp-content/plugins/bws-linkedin/bws_menu/product_list.php:9
    • > PHP Fatal error
      Uncaught Error: Call to undefined function register_activation_hook() in wp-content/plugins/bws-linkedin/bws-linkedin.php:553
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_action() in wp-content/plugins/bws-linkedin/bws_menu/class-bws-settings.php:1452

User-side errors 0% from 1 test

🔹 Test weight: 20 | This is just a short smoke test looking for browser issues
Please fix the following user-side errors
    • > GET request to /wp-admin/linkedin.php
    • > Network (severe)
    wp-admin/linkedin.php - Failed to load resource: the server responded with a status of 404 (Not Found)
    • > GET request to /wp-admin/linkedin.php?page=lnkdn-bws-panel
    • > Network (severe)
    wp-admin/linkedin.php?page=lnkdn-bws-panel - Failed to load resource: the server responded with a status of 404 (Not Found)

Optimizations

Plugin configuration 97% from 29 tests

readme.txt 94% from 16 tests

The readme.txt file is undoubtedly the most important file in your plugin, preparing it for public listing on WordPress.org
Attributes that need to be fixed:
  • Screenshots: These screenshots require images: #1 (LinkedIn Buttons in the front-end.), #2 (LinkedIn Settings Page.), #3 (Adding shortcode into the content.)
You can take inspiration from this readme.txt

bws-linkedin/bws-linkedin.php Passed 13 tests

This is the main PHP file of "BestWebSoft's LinkedIn" version 1.1.4, providing information about the plugin in the header fields and serving as the principal entry point to the plugin's functions
76 characters long description:
Add LinkedIn Share and Follow buttons to WordPress posts, pages and widgets.

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
No dangerous file extensions were detected19,158 lines of code in 40 files:
LanguageFilesBlank linesComment linesLines of code
PO File113,6235,3067,981
CSS101892745,566
PHP94806234,966
JavaScript627110495
SVG400150

PHP code Passed 2 tests

This is a very shot review of cyclomatic complexity and code structure
There are no cyclomatic complexity problems detected for this plugin
Cyclomatic complexity
Average complexity per logical line of code0.61
Average class complexity88.33
▷ Minimum class complexity21.00
▷ Maximum class complexity210.00
Average method complexity10.70
▷ Minimum method complexity1.00
▷ Maximum method complexity79.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes3
▷ Abstract classes00.00%
▷ Concrete classes3100.00%
▷ Final classes00.00%
Methods27
▷ Static methods00.00%
▷ Public methods2177.78%
▷ Protected methods00.00%
▷ Private methods622.22%
Functions71
▷ Named functions71100.00%
▷ Anonymous functions00.00%
Constants2
▷ Global constants2100.00%
▷ Class constants00.00%
▷ Public constants00.00%

Plugin size 50% from 2 tests

Image compression 50% from 2 tests

It is recommended to compress PNG files in your plugin to minimize bandwidth usage
64 PNG files occupy 3.15MB with 1.03MB in potential savings
Potential savings
Compression of 5 random PNG files using pngquant
FileSize - originalSize - compressedSavings
bws_menu/css/jquery-ui-styles/1.10.4/images/ui-bg_glass_65_ffffff_1x400.png0.25KB0.11KB▼ 54.83%
bws_menu/css/jquery-ui-styles/1.12.1/images/ui-icons_2e83ff_256x240.png4.57KB4.18KB▼ 8.43%
bws_menu/css/jquery-ui-styles/1.11.4/images/ui-icons_454545_256x240.png6.83KB4.17KB▼ 38.86%
bws_menu/css/jquery-ui-styles/1.12.1/images/ui-icons_cd0a0a_256x240.png4.57KB4.18KB▼ 8.43%
bws_menu/css/jquery-ui-styles/1.10.4/images/ui-bg_glass_95_fef1ec_1x400.png0.38KB0.17KB▼ 53.39%