10% yasip

Code Review | Yet Another Social Media Icon Plugin (YASIP)

WordPress plugin Yet Another Social Media Icon Plugin (YASIP) scored10%from 54 tests.

About plugin

  • Plugin page: yasip
  • Plugin version: 1.2
  • PHP version: 7.4.16
  • WordPress compatibility: 3.0-5.3.2
  • WordPress version: 6.3.1
  • First release: Sep 12, 2013
  • Latest release: Feb 11, 2020
  • Number of updates: 13
  • Update frequency: every 180.2 days
  • Top authors: mitchbartlett (100%)

Code review

54 tests

User reviews

3 reviews

Install metrics

200+ active /9,383 total downloads

Benchmarks

Plugin footprint 40% from 16 tests

Installer 0% from 1 test

🔺 Critical test (weight: 50) | The install procedure must perform silently
Please fix the following installer errors
  • Install procedure had errors
    • > Deprecated in wp-content/plugins/yasip/plugin.php+30
    Methods with the same name as their class will not be constructors in a future version of PHP; yasip_Widget has a deprecated constructor

Server metrics [RAM: ▼1.83MB] [CPU: ▼51.48ms] Passed 4 tests

An overview of server-side resources used by Yet Another Social Media Icon Plugin (YASIP)
This plugin has minimal impact on server resources
PageMemory (MB)CPU Time (ms)
Home /2.15 ▼1.314.93 ▼36.26
Dashboard /wp-admin2.17 ▼1.135.50 ▼45.81
Posts /wp-admin/edit.php2.17 ▼1.185.75 ▼41.83
Add New Post /wp-admin/post-new.php2.17 ▼3.716.05 ▼82.00
Media Library /wp-admin/upload.php2.17 ▼1.054.83 ▼30.40

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

Filesystem and database footprint
This plugin was installed successfully
Filesystem: 158 new files
Database: no new tables, 7 new options
New WordPress options
widget_recent-posts
theysaidso_admin_options
widget_yasip
widget_recent-comments
can_compress_scripts
db_upgraded
widget_theysaidso_widget

Browser metrics Passed 4 tests

An overview of browser requirements for Yet Another Social Media Icon Plugin (YASIP)
Minimal impact on browser resources
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,800 ▲6513.25 ▼1.141.78 ▼0.1745.39 ▼0.05
Dashboard /wp-admin2,206 ▲184.85 ▼0.04110.86 ▼4.7138.42 ▼3.77
Posts /wp-admin/edit.php2,089 ▼32.05 ▲0.0839.37 ▲1.9634.16 ▲0.93
Add New Post /wp-admin/post-new.php1,542 ▲2818.08 ▲0.56604.41 ▼96.4160.40 ▲4.16
Media Library /wp-admin/upload.php1,388 ▼34.20 ▼0.0696.33 ▼4.3040.78 ▼4.67

Uninstaller [IO: ▲0.00MB] [DB: ▲0.00MB] 50% 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
  • Uninstall procedure had uncaught errors
    • > Deprecated in wp-content/plugins/yasip/plugin.php+30
    Methods with the same name as their class will not be constructors in a future version of PHP; yasip_Widget has a deprecated constructor
  • Zombie WordPress options were found after uninstall: 7 options
    • widget_yasip
    • widget_theysaidso_widget
    • db_upgraded
    • can_compress_scripts
    • widget_recent-posts
    • theysaidso_admin_options
    • widget_recent-comments

Smoke tests 75% 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)
Good news, no errors were detected

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
  • 1× GET requests to PHP files trigger server-side errors or Error 500 responses:
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_action() in wp-content/plugins/yasip/plugin.php:21

User-side errors Passed 1 test

🔹 Test weight: 20 | Just a short smoke test targeting errors on the browser (console and network errors and warnings)
Everything seems fine, but this is not an exhaustive test

Optimizations

Plugin configuration 93% 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
These attributes need to be fixed:
  • Plugin Name: Write the name of your plugin instead of "Plugin Name" on the first line ( === yasip === )
You can look at the official readme.txt

yasip/plugin.php 92% from 13 tests

Analyzing the main PHP file in "Yet Another Social Media Icon Plugin (YASIP)" version 1.2
You should first fix the following items:
  • Main file name: It is recommended to name the main PHP file as the plugin slug ("yasip.php" instead of "plugin.php")

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
Everything looks great! No dangerous files found in this plugin158 lines of code in 1 file:
LanguageFilesBlank linesComment linesLines of code
PHP13218158

PHP code Passed 2 tests

This plugin's cyclomatic complexity and code structure detailed below
There were no cyclomatic complexity issued detected
Cyclomatic complexity
Average complexity per logical line of code0.11
Average class complexity6.00
▷ Minimum class complexity6.00
▷ Maximum class complexity6.00
Average method complexity2.00
▷ Minimum method complexity1.00
▷ Maximum method complexity5.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes1
▷ Abstract classes00.00%
▷ Concrete classes1100.00%
▷ Final classes00.00%
Methods5
▷ Static methods00.00%
▷ Public methods5100.00%
▷ Protected methods00.00%
▷ Private methods00.00%
Functions1
▷ Named functions1100.00%
▷ Anonymous functions00.00%
Constants0
▷ Global constants00.00%
▷ Class constants00.00%
▷ Public constants00.00%

Plugin size Passed 2 tests

Image compression Passed 2 tests

It is recommended to compress PNG files in your plugin to minimize bandwidth usage
156 PNG files occupy 0.35MB with 0.08MB in potential savings
Potential savings
Compression of 5 random PNG files using pngquant
FileSize - originalSize - compressedSavings
images/orbs/tumblr_48x48.png4.84KB2.75KB▼ 43.21%
images/orbs/vine_24x24.png1.73KB1.57KB▼ 9.59%
images/flat/rss_48x48.png4.16KB2.68KB▼ 35.59%
images/flat/flickr_48x48.png3.43KB2.46KB▼ 28.34%
images/silver/tumblr_24x24.png1.23KB1.38KB0.00%