84% simple-social-images

Code Review | Simple Social Images

WordPress plugin Simple Social Images scored84%from 54 tests.

About plugin

  • Plugin page: simple-social-images
  • Plugin version: 1.0
  • PHP compatiblity: 8.0+
  • PHP version: 7.4.16
  • WordPress compatibility: 6.0-6.0.2
  • WordPress version: 6.3.1
  • First release: Sep 21, 2022
  • Latest release: Sep 21, 2022
  • Number of updates: 2
  • Update frequency: N/A
  • Top authors: highrisedigital (100%)

Code review

54 tests

User reviews

1 review

Install metrics

10+ active /233 total downloads

Benchmarks

Plugin footprint 83% 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.38MB] [CPU: ▼3.13ms] Passed 4 tests

This is a short check of server-side resources used by Simple Social Images
This plugin has minimal impact on server resources
PageMemory (MB)CPU Time (ms)
Home /3.81 ▲0.3543.28 ▼2.34
Dashboard /wp-admin3.74 ▲0.4455.87 ▲3.72
Posts /wp-admin/edit.php3.79 ▲0.4349.00 ▼3.94
Add New Post /wp-admin/post-new.php6.26 ▲0.3888.74 ▼9.96
Media Library /wp-admin/upload.php3.60 ▲0.3741.57 ▲6.32
Simple Social Images /wp-admin/options-general.php?page=hd-ssi-settings3.6545.68

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

How much does this plugin use your filesystem and database?
The plugin installed successfully
Filesystem: 37 new files
Database: no new tables, 37 new options
New WordPress options
hd_ssi_title_offset_x
hd_ssi_version
hd_ssi_logo_offset_y
hd_ssi_title_text_transform
hd_ssi_title_background_gradient
hd_ssi_use_image
hd_ssi_title_font_size
hd_ssi_title_offset_y
hd_ssi_image_width
hd_ssi_title_style
...

Browser metrics Passed 4 tests

A check of browser resources used by Simple Social Images
This plugin has a minimal impact on browser resources
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,831 ▲8513.36 ▼1.012.26 ▲0.4246.12 ▲2.76
Dashboard /wp-admin2,215 ▲245.86 ▲1.00116.57 ▲14.7943.94 ▲1.80
Posts /wp-admin/edit.php2,095 ▲62.00 ▲0.0136.54 ▼2.5037.49 ▼0.59
Add New Post /wp-admin/post-new.php1,534 ▲2021.05 ▲3.57694.41 ▼12.1066.47 ▲12.45
Media Library /wp-admin/upload.php1,394 ▲64.20 ▼0.02112.05 ▲10.6550.44 ▲3.18
Simple Social Images /wp-admin/options-general.php?page=hd-ssi-settings2,4394.2981.8684.13

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
Please fix the following items
  • This plugin did not uninstall successfully, leaving 37 options in the database
    • hd_ssi_image_offset_y
    • theysaidso_admin_options
    • hd_ssi_image_offset_x
    • hd_ssi_use_featured_image
    • hd_ssi_title_offset_x
    • hd_ssi_image_position
    • hd_ssi_version
    • hd_ssi_title_offset_y
    • hd_ssi_image_width
    • widget_theysaidso_widget
    • ...

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)
The smoke test was a success, however most plugin functionality was not tested

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
  • 14× GET requests to PHP files have triggered server-side errors or warnings (only 10 are shown):
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_action() in wp-content/plugins/simple-social-images/inc/settings.php:72
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_filter() in wp-content/plugins/simple-social-images/inc/plugins/all-in-one-seo.php:33
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_filter() in wp-content/plugins/simple-social-images/inc/plugins/rank-math-seo.php:65
    • > PHP Fatal error
      Uncaught Error: Call to undefined function plugins_url() in wp-content/plugins/simple-social-images/simple-social-images.php:16
    • > PHP Fatal error
      Uncaught Error: Call to undefined function esc_attr() in wp-content/plugins/simple-social-images/templates/default.php:1
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_action() in wp-content/plugins/simple-social-images/inc/enqueue.php:87
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_action() in wp-content/plugins/simple-social-images/inc/meta-box.php:28
    • > PHP Fatal error
      Uncaught Error: Call to undefined function do_action() in wp-content/plugins/simple-social-images/endpoints/generate-html.php:28
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_action() in wp-content/plugins/simple-social-images/inc/functions.php:26
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_action() in wp-content/plugins/simple-social-images/inc/admin-menu.php:19

User-side errors Passed 1 test

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

Optimizations

Plugin configuration 93% from 29 tests

readme.txt Passed 16 tests

The readme.txt file describes your plugin functionality and requirements and it is parsed to prepare the your plugin's listing
7 plugin tags: social media, facebook, linkedin, social sharing, open graph...

simple-social-images/simple-social-images.php 85% from 13 tests

The main PHP file in "Simple Social Images" ver. 1.0 adds more information about the plugin and also serves as the entry point for this plugin
Please make the necessary changes and fix the following:
  • Domain Path: The domain path folder does not exist ("/languages/")
  • Description: If Twitter did it, so should we! Keep the description under 140 characters (currently 204 characters long)

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | A short review of files and their extensions; it is not recommended to include executable files
Good job! No executable or dangerous file extensions detected3,564 lines of code in 31 files:
LanguageFilesBlank linesComment linesLines of code
PHP151,0159672,127
HTML111140810
CSS2633332
JavaScript2256142294
SVG1001

PHP code Passed 2 tests

A brief analysis of cyclomatic complexity and code structure for this plugin
No complexity issues detected
Cyclomatic complexity
Average complexity per logical line of code0.29
Average class complexity0.00
▷ Minimum class complexity0.00
▷ Maximum class complexity0.00
Average method complexity0.00
▷ Minimum method complexity0.00
▷ Maximum method complexity0.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes0
▷ Abstract classes00.00%
▷ Concrete classes00.00%
▷ Final classes00.00%
Methods0
▷ Static methods00.00%
▷ Public methods00.00%
▷ Protected methods00.00%
▷ Private methods00.00%
Functions110
▷ Named functions10999.09%
▷ Anonymous functions10.91%
Constants3
▷ Global constants3100.00%
▷ Class constants00.00%
▷ Public constants00.00%

Plugin size Passed 2 tests

Image compression Passed 2 tests

Using a strong compression for your PNG files is a great way to speed-up your plugin
There are no PNG files in this plugin