84% wp-share-simple

Code Review | WP Share Simple

WordPress plugin WP Share Simple scored84%from 54 tests.

About plugin

  • Plugin page: wp-share-simple
  • Plugin version: 1.3
  • PHP version: 7.4.16
  • WordPress compatibility: 3.0.1-4.7.2
  • WordPress version: 6.3.1
  • First release: Dec 16, 2014
  • Latest release: Sep 13, 2015
  • Number of updates: 19
  • Update frequency: every 42.3 days
  • Top authors: mannemvamsi (100%)

Code review

54 tests

User reviews

1 review

Install metrics

10+ active /5,538 total downloads

Benchmarks

Plugin footprint 83% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | It is important to correctly install your plugin, without throwing errors or notices
Installer ran successfully

Server metrics [RAM: ▲0.04MB] [CPU: ▼2.53ms] Passed 4 tests

A check of server-side resources used by WP Share Simple
This plugin has minimal impact on server resources
PageMemory (MB)CPU Time (ms)
Home /3.50 ▲0.0443.71 ▲2.72
Dashboard /wp-admin3.34 ▲0.0444.98 ▼1.92
Posts /wp-admin/edit.php3.39 ▲0.0446.18 ▲1.98
Add New Post /wp-admin/post-new.php5.92 ▲0.0481.66 ▼3.91
Media Library /wp-admin/upload.php3.27 ▲0.0430.79 ▼6.26
WP Share Simple /wp-admin/options-general.php?page=wp_share_simple3.2330.06

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

Browser metrics Passed 4 tests

A check of browser resources used by WP Share Simple
This plugin has a minimal impact on browser resources
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,917 ▲18213.54 ▼0.839.43 ▲7.6837.73 ▼10.98
Dashboard /wp-admin2,207 ▲155.89 ▲0.95101.05 ▼4.1040.39 ▼0.24
Posts /wp-admin/edit.php2,093 ▲72.06 ▲0.0337.84 ▲1.4237.76 ▲3.81
Add New Post /wp-admin/post-new.php1,538 ▲2523.38 ▲5.73668.66 ▲17.3455.02 ▲2.93
Media Library /wp-admin/upload.php1,395 ▲74.17 ▲0.0196.40 ▲1.1544.26 ▲3.38
WP Share Simple /wp-admin/options-general.php?page=wp_share_simple8502.0725.1332.95

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

🔸 Tests weight: 35 | Verifying that this plugin uninstalls completely without leaving any traces
You still need to fix the following
  • The uninstall procedure has failed, leaving 6 options in the database
    • widget_recent-comments
    • widget_recent-posts
    • can_compress_scripts
    • db_upgraded
    • widget_theysaidso_widget
    • theysaidso_admin_options

Smoke tests 75% from 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | A smoke test targeting server-side errors
The smoke test was a success, however most plugin functionality was not tested

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
Please fix the following
  • 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/wp-share-simple/wp-share-admin.php:9

User-side errors Passed 1 test

🔹 Test weight: 20 | This is a smoke test targeting browser errors/issues
Everything seems fine, but this is not an exhaustive test

Optimizations

Plugin configuration 93% from 29 tests

readme.txt 88% from 16 tests

Perhaps the most important file in your plugin readme.txt gets parsed in order to generate the public listing of your plugin
Attributes that require attention:
  • Plugin Name: You should set the name of your plugin on the first line ( === wp-share-simple === )
  • Screenshots: These screenshots have no corresponding images in /assets: #1 (Admin Options Page), #2 (Flat Style Share Buttons), #3 (Default Style Share Buttons)
You can look at the official readme.txt

wp-share-simple/wp-share-simple.php Passed 13 tests

The entry point to "WP Share Simple" version 1.3 is a PHP file that has certain tags in its header comment area
47 characters long description:
A simple plugin to show the social shared count

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | A short check of programming languages and file extensions; no executable files are allowed
No dangerous file extensions were detected464 lines of code in 6 files:
LanguageFilesBlank linesComment linesLines of code
PHP26430215
CSS270214
JavaScript26635

PHP code Passed 2 tests

This is a short overview of cyclomatic complexity and code structure for this plugin
Although this was not an exhaustive test, there were no cyclomatic complexity issues detected
Cyclomatic complexity
Average complexity per logical line of code0.38
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%
Functions12
▷ Named functions12100.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
6 PNG files occupy 0.03MB with 0.02MB in potential savings
Potential savings
Compression of 5 random PNG files using pngquant
FileSize - originalSize - compressedSavings
banner-772x250.png11.54KB4.12KB▼ 64.32%
assets/facebook.png1.11KB0.19KB▼ 82.75%
screenshot-2.png5.13KB2.60KB▼ 49.32%
screenshot-3.png3.86KB2.81KB▼ 27.15%
screenshot-1.png10.27KB5.49KB▼ 46.52%