62% onlywire-bookmark-share-button

Code Review | OnlyWire for WordPress [OFFICIAL]

WordPress plugin OnlyWire for WordPress [OFFICIAL] scored 62% from 54 tests.

About plugin

  • Plugin page: onlywire-bookmark...
  • Plugin version: 2.0.0
  • PHP version: 7.4.16
  • WordPress compatibility: 3.0-4.9
  • WordPress version: 6.3.1
  • First release: Jun 29, 2009
  • Latest release: Sep 17, 2018
  • Number of updates: 255
  • Update frequency: every 13.2 days
  • Top authors: craiglurey (100%)

Code review

54 tests

User reviews

6 reviews

Install metrics

800+ active / 174,946 total downloads

Benchmarks

Plugin footprint 65% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | It is important to correctly install your plugin, without throwing errors or notices
The plugin installed gracefully, with no errors

Server metrics [RAM: ▼0.89MB] [CPU: ▼31.54ms] Passed 4 tests

This is a short check of server-side resources used by OnlyWire for WordPress [OFFICIAL]
Normal server usage
PageMemory (MB)CPU Time (ms)
Home /3.52 ▲0.0639.59 ▼3.47
Dashboard /wp-admin3.05 ▼0.2524.08 ▼26.69
Posts /wp-admin/edit.php3.05 ▼0.3023.37 ▼22.56
Add New Post /wp-admin/post-new.php3.05 ▼2.8324.55 ▼67.15
Media Library /wp-admin/upload.php3.05 ▼0.1826.20 ▼9.77
OnlyWire Settings /wp-admin/options-general.php?page=onlywireoptions3.0527.89

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

How much does this plugin use your filesystem and database?
This plugin installed successfully
Filesystem: 14 new files
Database: no new tables, 10 new options
New WordPress options
widget_theysaidso_widget
ow_password
db_upgraded
widget_recent-comments
can_compress_scripts
widget_recent-posts
ow_autopost
ow_service_logins
theysaidso_admin_options
ow_username

Browser metrics Passed 4 tests

Checking browser requirements for OnlyWire for WordPress [OFFICIAL]
There were no issues detected in relation to browser resource usage
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,804 ▲4713.18 ▼1.204.93 ▲2.8443.21 ▼4.21
Dashboard /wp-admin2,207 ▲225.83 ▼0.03101.16 ▼18.4539.97 ▼7.57
Posts /wp-admin/edit.php2,093 ▲42.01 ▼0.0234.42 ▲0.5635.97 ▲0.40
Add New Post /wp-admin/post-new.php6,465 ▲4,94520.22 ▼3.21869.40 ▲234.1460.76 ▲8.01
Media Library /wp-admin/upload.php1,389 ▼24.17 ▼0.0496.23 ▼7.3042.94 ▼5.94
OnlyWire Settings /wp-admin/options-general.php?page=onlywireoptions9582.0727.5163.84

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

🔸 Tests weight: 35 | Verifying that this plugin uninstalls completely without leaving any traces
These items require your attention
  • Uninstall procedure had uncaught errors
    • > User deprecated in wp-includes/functions.php+5737
    Function has_cap was called with an argument that is deprecated since version 2.0.0! Usage of user levels is deprecated. Use capabilities instead.
  • The uninstall procedure has failed, leaving 10 options in the database
    • db_upgraded
    • ow_username
    • theysaidso_admin_options
    • widget_recent-posts
    • ow_password
    • widget_recent-comments
    • ow_service_logins
    • can_compress_scripts
    • widget_theysaidso_widget
    • ow_autopost

Smoke tests 25% from 4 tests

Server-side errors 0% from 1 test

🔹 Test weight: 20 | This is a short smoke test looking for server-side errors
Almost there, just fix the following server-side errors
  • 2 occurences, only the last one shown
    • > GET request to /wp-admin/options-general.php?page=onlywireoptions
    • > User deprecated in wp-includes/functions.php+5737
    Function has_cap was called with an argument that is deprecated since version 2.0.0! Usage of user levels is deprecated. Use capabilities instead.
  • 2 occurences, only the last one shown
    • > GET request to /wp-admin/options-general.php?page=onlywireoptions
    • > Notice in wp-content/plugins/onlywire-bookmark-share-button/owbutton_wordpress.php+207
    Trying to get property 'success' of non-object
    • > GET request to /wp-admin/options-general.php?page=onlywireoptions
    • > Notice in wp-content/plugins/onlywire-bookmark-share-button/owbutton_wordpress.php+250
    Trying to get property 'networks' of non-object
    • > GET request to /wp-admin/options-general.php?page=onlywireoptions
    • > Warning in wp-content/plugins/onlywire-bookmark-share-button/owbutton_wordpress.php+250
    count(): Parameter must be an array or an object that implements Countable

SRP 0% 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 fix the following items
  • 1× PHP files perform the task of outputting text when accessed with GET requests:
    • > /wp-content/plugins/onlywire-bookmark-share-button/ow_auth.php
  • 3× PHP files trigger server-side errors or warnings when accessed directly:
    • > PHP Notice
      Undefined variable: auth_pw in wp-content/plugins/onlywire-bookmark-share-button/ow_auth.php on line 9
    • > PHP Fatal error
      Uncaught Error: Call to undefined function register_activation_hook() in wp-content/plugins/onlywire-bookmark-share-button/owbutton_wordpress.php:19
    • > PHP Notice
      Undefined variable: auth_user in wp-content/plugins/onlywire-bookmark-share-button/ow_auth.php on line 9

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 on the user side

Optimizations

Plugin configuration 93% from 29 tests

readme.txt 94% 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
These attributes need to be fixed:
  • Tags: There are too many tags (20 tag instead of maximum 10)
The official readme.txt might help

onlywire-bookmark-share-button/owbutton_wordpress.php 92% from 13 tests

This is the main PHP file of "OnlyWire for WordPress [OFFICIAL]" version 2.0.0, providing information about the plugin in the header fields and serving as the principal entry point to the plugin's functions
It is important to fix the following:
  • Main file name: It is recommended to name the main PHP file as the plugin slug ("onlywire-bookmark-share-button.php" instead of "owbutton_wordpress.php")

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
Everything looks great! No dangerous files found in this plugin804 lines of code in 8 files:
LanguageFilesBlank linesComment linesLines of code
PHP39338339
CSS1510274
SVG401191

PHP code Passed 2 tests

A short review of cyclomatic complexity and code structure
All good! No complexity issues found
Cyclomatic complexity
Average complexity per logical line of code0.28
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%
Functions10
▷ Named functions10100.00%
▷ Anonymous functions00.00%
Constants4
▷ Global constants4100.00%
▷ Class constants00.00%
▷ Public constants00.00%

Plugin size Passed 2 tests

Image compression Passed 2 tests

All PNG images should be compressed to minimize bandwidth usage for end users
4 PNG files occupy 0.21MB with 0.13MB in potential savings
Potential savings
Compression of 4 random PNG files using pngquant
FileSize - originalSize - compressedSavings
screenshot-1.png33.42KB14.18KB▼ 57.57%
screenshot-2.png42.35KB18.09KB▼ 57.29%
banner-1544x500.png109.15KB22.68KB▼ 79.22%
banner-772x250.png27.01KB9.08KB▼ 66.38%