10% wp-social-media-icon

Code Review | WP Social Media Icon

WordPress plugin WP Social Media Icon scored 10% from 54 tests.

About plugin

  • Plugin page: wp-social-media-icon
  • Plugin version: 1.0.2
  • PHP version: 7.4.16
  • WordPress compatibility: 3.0.1-4.8
  • WordPress version: 5.8.1
  • First release: Aug 21, 2015
  • Latest release: Jun 8, 2017
  • Number of updates: 6
  • Update frequency: every 116.5 days
  • Top authors: raj.prince587 (100%)

Code review

54 tests

User reviews

1 review

Install metrics

10+ active / 939 total downloads

Benchmarks

Plugin footprint 40% from 16 tests

Installer 0% from 1 test

🔺 Critical test (weight: 50) | All plugins must install correctly, without throwing any errors, warnings, or notices
You still need to fix the following installer errors
  • The plugin cannot be installed
    • > Deprecated in wp-content/plugins/wp-social-media-icon/wp-social-media-icon.php+12
    Methods with the same name as their class will not be constructors in a future version of PHP; SOCIALICONwidget has a deprecated constructor

Server metrics [RAM: ▼1.79MB] [CPU: ▼202.55ms] Passed 4 tests

This is a short check of server-side resources used by WP Social Media Icon
Normal server usage
PageMemory (MB)CPU Time (ms)
Home /1.84 ▼0.995.86 ▼33.08
Dashboard /wp-admin1.86 ▼1.195.41 ▼53.20
Posts /wp-admin/edit.php1.86 ▼1.257.34 ▼47.60
Add New Post /wp-admin/post-new.php1.86 ▼3.575.55 ▼676.30
Media Library /wp-admin/upload.php1.86 ▼1.146.02 ▼33.11

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

How much does this plugin use your filesystem and database?
This plugin was installed successfully
Filesystem: 16 new files
Database: no new tables, 2 new options
New WordPress options
widget_phonenowidget
widget_socialiconwidget

Browser metrics Passed 4 tests

An overview of browser requirements for WP Social Media Icon
There were no issues detected in relation to browser resource usage
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /3,706 ▲11016.04 ▲0.4111.81 ▲1.2454.43 ▲2.37
Dashboard /wp-admin2,973 ▲426.01 ▲0.07172.63 ▼0.60128.60 ▲8.26
Posts /wp-admin/edit.php2,736 ▼32.72 ▼0.0179.34 ▼2.9495.74 ▲6.18
Add New Post /wp-admin/post-new.php1,604 ▲2318.43 ▼2.92406.78 ▼5.48118.38 ▼4.05
Media Library /wp-admin/upload.php1,807 ▼05.02 ▲0.01187.10 ▲18.72125.25 ▲3.89

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

🔸 Tests weight: 35 | Verifying that this plugin uninstalls completely without leaving any traces
It is recommended to fix the following
  • Uninstall procedure validation failed for this plugin
    • > Deprecated in wp-content/plugins/wp-social-media-icon/wp-social-media-icon.php+12
    Methods with the same name as their class will not be constructors in a future version of PHP; SOCIALICONwidget has a deprecated constructor
  • This plugin does not fully uninstall, leaving 2 options in the database
    • widget_socialiconwidget
    • widget_phonenowidget

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 | SRP (Single-Responsibility Principle) - PHP files must act as libraries and never output text or perform any action when accessed directly in a browser
Please take a closer look at the following
  • 1× PHP files trigger server-side errors or warnings when accessed directly:
    • > PHP Fatal error
      Uncaught Error: Class 'WP_Widget' not found in wp-content/plugins/wp-social-media-icon/wp-social-media-icon.php:12

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 Passed 29 tests

readme.txt Passed 16 tests

You should put a lot of thought into formatting readme.txt as it is used by WordPress.org to prepare the public listing of your plugin
2 plugin tags: social media icons, wp social media

wp-social-media-icon/wp-social-media-icon.php Passed 13 tests

The entry point to "WP Social Media Icon" version 1.0.2 is a PHP file that has certain tags in its header comment area
59 characters long description:
WP Social Media Icon can be used in any theme of wordpress.

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
Everything looks great! No dangerous files found in this plugin448 lines of code in 9 files:
LanguageFilesBlank linesComment linesLines of code
SVG606278
PHP16016153
CSS13016
HTML1001

PHP code Passed 2 tests

An overview of cyclomatic complexity and code structure
No complexity issues detected
Cyclomatic complexity
Average complexity per logical line of code0.33
Average class complexity14.00
▷ Minimum class complexity8.00
▷ Maximum class complexity20.00
Average method complexity4.25
▷ Minimum method complexity1.00
▷ Maximum method complexity8.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes2
▷ Abstract classes00.00%
▷ Concrete classes2100.00%
▷ Final classes00.00%
Methods8
▷ Static methods00.00%
▷ Public methods8100.00%
▷ Protected methods00.00%
▷ Private methods00.00%
Functions3
▷ Named functions3100.00%
▷ Anonymous functions00.00%
Constants0
▷ Global constants00.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
6 compressed PNG files occupy 0.01MB
Potential savings
Compression of 5 random PNG files using pngquant
FileSize - originalSize - compressedSavings
images/instagram.png1.64KB1.47KB▼ 10.39%
images/linkedin.png1.18KB1.31KB0.00%
images/livejournal.png1.06KB1.28KB0.00%
images/facebook.png1.20KB1.02KB▼ 14.90%
images/pinterest.png1.81KB1.46KB▼ 19.41%