84% meks-smart-social-widget

Code Review | Meks Smart Social Widget

WordPress plugin Meks Smart Social Widget scored84%from 54 tests.

About plugin

  • Plugin page: meks-smart-social...
  • Plugin version: 1.6.3
  • PHP version: 7.4.16
  • WordPress compatibility: 3.0-6.3
  • WordPress version: 6.3.1
  • First release: Jan 14, 2014
  • Latest release: Sep 21, 2023
  • Number of updates: 55
  • Update frequency: every 64.3 days
  • Top authors: mekshq (100%)

Code review

54 tests

User reviews

8 reviews

Install metrics

30,000+ active /466,095 total downloads

Benchmarks

Plugin footprint 83% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | Verifying that this plugin installs correctly without errors
The plugin installed gracefully, with no errors

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

Server-side resources used by Meks Smart Social Widget
This plugin has minimal impact on server resources
PageMemory (MB)CPU Time (ms)
Home /3.55 ▲0.1041.63 ▼1.85
Dashboard /wp-admin3.40 ▲0.0945.56 ▼2.55
Posts /wp-admin/edit.php3.45 ▲0.0948.16 ▼0.19
Add New Post /wp-admin/post-new.php6.00 ▲0.1190.01 ▼1.91
Media Library /wp-admin/upload.php3.32 ▲0.0933.73 ▲1.95

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

Input-output and database impact of this plugin
The plugin installed successfully
Filesystem: 22 new files
Database: no new tables, 7 new options
New WordPress options
theysaidso_admin_options
widget_recent-posts
can_compress_scripts
widget_theysaidso_widget
db_upgraded
widget_recent-comments
widget_mks_social_widget

Browser metrics Passed 4 tests

Checking browser requirements for Meks Smart Social Widget
Minimal impact on browser resources
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,800 ▲4314.47 ▲0.161.54 ▼1.2539.25 ▼6.85
Dashboard /wp-admin2,198 ▲134.92 ▼0.97101.44 ▼20.8937.37 ▼7.04
Posts /wp-admin/edit.php2,094 ▲82.23 ▲0.2237.13 ▼1.5634.11 ▼0.02
Add New Post /wp-admin/post-new.php1,512 ▼2117.48 ▼5.75683.48 ▲35.0838.38 ▼26.18
Media Library /wp-admin/upload.php1,383 ▼54.18 ▲0.00102.15 ▼2.6643.55 ▼2.17

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
It is recommended to fix the following
  • The uninstall procedure has failed, leaving 7 options in the database
    • widget_recent-posts
    • can_compress_scripts
    • widget_mks_social_widget
    • widget_theysaidso_widget
    • theysaidso_admin_options
    • widget_recent-comments
    • db_upgraded

Smoke tests 75% from 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 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
The following issues need your attention
  • 2× PHP files trigger server-side errors or warnings when accessed directly:
    • > PHP Fatal error
      Uncaught Error: Call to undefined function trailingslashit() in wp-content/plugins/meks-smart-social-widget/meks-smart-social-widget.php:33
    • > PHP Fatal error
      Uncaught Error: Class 'WP_Widget' not found in wp-content/plugins/meks-smart-social-widget/inc/class-social-widget.php:6

User-side errors Passed 1 test

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

Optimizations

Plugin configuration 96% from 29 tests

readme.txt Passed 16 tests

The readme.txt file uses markdown syntax to describe your plugin to the world
9 plugin tags: widget, instagram, pinterest, dribble, social...

meks-smart-social-widget/meks-smart-social-widget.php 92% from 13 tests

The entry point to "Meks Smart Social Widget" version 1.6.3 is a PHP file that has certain tags in its header comment area
Please make the necessary changes and fix the following:
  • Description: The description should be shorter than 140 characters (currently 207 characters long)

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | This is an overview of file extensions present in this plugin and a short test that no dangerous files are bundled with this plugin
Success! There were no dangerous files found in this plugin2,517 lines of code in 7 files:
LanguageFilesBlank linesComment linesLines of code
CSS255581,728
PHP26531432
SVG100269
PO File1202054
JavaScript113334

PHP code Passed 2 tests

This plugin's cyclomatic complexity and code structure detailed below
This plugin has no cyclomatic complexity problems
Cyclomatic complexity
Average complexity per logical line of code0.08
Average class complexity10.00
▷ Minimum class complexity10.00
▷ Maximum class complexity10.00
Average method complexity2.00
▷ Minimum method complexity1.00
▷ Maximum method complexity6.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes1
▷ Abstract classes00.00%
▷ Concrete classes1100.00%
▷ Final classes00.00%
Methods9
▷ Static methods00.00%
▷ Public methods888.89%
▷ Protected methods111.11%
▷ Private methods00.00%
Functions2
▷ Named functions2100.00%
▷ Anonymous functions00.00%
Constants3
▷ Global constants3100.00%
▷ Class constants00.00%
▷ Public constants00.00%

Plugin size Passed 2 tests

Image compression Passed 2 tests

Often times overlooked, PNG files can occupy unnecessary space in your plugin
8 compressed PNG files occupy 0.00MB
Potential savings
Compression of 5 random PNG files using pngquant
FileSize - originalSize - compressedSavings
img/social_icons/tencent_ico.png0.43KB0.45KB0.00%
img/social_icons/picasa_ico.png0.47KB0.48KB0.00%
img/social_icons/me2day_ico.png0.39KB0.40KB0.00%
img/social_icons/cargo_ico.png0.35KB0.35KB0.00%
img/social_icons/icloud_ico.png0.34KB0.35KB0.00%