77% biblegateway-links-shortcode

Code Review | BibleGateway Links Shortcode

WordPress plugin BibleGateway Links Shortcodescored77%from 54 tests.

About plugin

  • Plugin page: biblegateway-link...
  • Plugin version: 0.1.7
  • PHP version: 7.4.16
  • WordPress compatibility: 3.2-4.2.0
  • WordPress version: 6.3.1
  • First release: Jun 25, 2013
  • Latest release: Jan 16, 2015
  • Number of updates: 17
  • Update frequency: every 33.5 days
  • Top authors: jtsternberg (100%)

Code review

54 tests

User reviews

1 review

Install metrics

100+ active /3,651 total downloads

Benchmarks

Plugin footprint 83% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | All plugins must install correctly, without throwing any errors, warnings, or notices
The plugin installed successfully, without throwing any errors or notices

Server metrics [RAM: ▲0.01MB] [CPU: ▼5.42ms] Passed 4 tests

Server-side resources used by BibleGateway Links Shortcode
No issues were detected with server-side resource usage
PageMemory (MB)CPU Time (ms)
Home /3.47 ▲0.0140.91 ▼0.38
Dashboard /wp-admin3.32 ▲0.0247.35 ▼6.97
Posts /wp-admin/edit.php3.37 ▲0.0248.33 ▼0.30
Add New Post /wp-admin/post-new.php5.91 ▲0.0393.07 ▼14.03
Media Library /wp-admin/upload.php3.24 ▲0.0236.50 ▲1.85
BibleGateway Links Shortcode /wp-admin/options-general.php?page=bgbible3.1930.64

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

Analyzing filesystem and database footprints of this plugin
This plugin was installed successfully
Filesystem: 7 new files
Database: no new tables, 6 new options
New WordPress options
theysaidso_admin_options
widget_recent-comments
db_upgraded
widget_recent-posts
can_compress_scripts
widget_theysaidso_widget

Browser metrics Passed 4 tests

BibleGateway Links Shortcode: an overview of browser usage
This plugin renders optimally with no browser resource issues detected
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,804 ▲5813.21 ▼1.181.66 ▼0.2141.51 ▼3.33
Dashboard /wp-admin2,207 ▲195.79 ▲0.89102.11 ▼8.5640.33 ▼8.42
Posts /wp-admin/edit.php2,103 ▲172.07 ▲0.0541.13 ▲3.7635.12 ▲0.23
Add New Post /wp-admin/post-new.php1,536 ▲1623.42 ▲0.39662.47 ▲2.0461.97 ▲8.08
Media Library /wp-admin/upload.php1,395 ▲44.21 ▼0.0096.75 ▲2.3542.20 ▲0.03
BibleGateway Links Shortcode /wp-admin/options-general.php?page=bgbible8332.0624.6324.66

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

🔸 Tests weight: 35 | All plugins must uninstall correctly, removing their source code and extra database tables they might have created
You still need to fix the following
  • The uninstall procedure has failed, leaving 6 options in the database
    • widget_recent-comments
    • theysaidso_admin_options
    • widget_recent-posts
    • widget_theysaidso_widget
    • can_compress_scripts
    • db_upgraded

Smoke tests 50% from 4 tests

Server-side errors 0% from 1 test

🔹 Test weight: 20 | Just a short smoke test targeting errors on the server (in the Apache logs)
These errors were triggered by the plugin
    • > GET request to /wp-admin/options-general.php?page=bgbible
    • > User deprecated in wp-includes/functions.php+5463
    Function screen_icon is deprecated since version 3.8.0 with no alternative available.
    • > GET request to /wp-admin/options-general.php?page=bgbible
    • > User deprecated in wp-includes/functions.php+5463
    Function get_screen_icon is deprecated since version 3.8.0 with no alternative available.

SRP 50% from 2 tests

🔹 Tests weight: 20 | The single-responsibility principle: PHP files have to remain inert when accessed directly, throwing no errors and performing no actions
Please fix the following
  • 1× PHP files trigger server-side errors or warnings when accessed directly:
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_action() in wp-content/plugins/biblegateway-links-shortcode/biblegateway-search-shortcode.php:58

User-side errors Passed 1 test

🔹 Test weight: 20 | A shallow check that no browser errors were triggered
Everything seems fine on the user side

Optimizations

Plugin configuration 87% from 29 tests

readme.txt 88% 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 your attention:
  • Screenshots: Add images for these screenshots: #1 (1) Highlight reference, 2) Optionally enter alternate text for display, 3) OK!), #2 (1) Place cursor where you want the reference, 2) Enter reference, 3) Optionally enter alternate text for display, 3) OK!)
  • Plugin Name: You should set the name of your plugin on the first line ( === BibleGateway Links Shortcode=== )
You can look at the official readme.txt

biblegateway-links-shortcode/biblegateway-search-shortcode.php 85% from 13 tests

Analyzing the main PHP file in "BibleGateway Links Shortcode" version 0.1.7
The following require your attention:
  • Main file name: The principal plugin file should be the same as the plugin slug ("biblegateway-links-shortcode.php" instead of "biblegateway-search-shortcode.php")
  • Description: Please keep the plugin description shorter than 140 characters (currently 159 characters long)

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | Executable files are not allowed as they can serve as attack vectors
Success! There were no dangerous files found in this plugin257 lines of code in 3 files:
LanguageFilesBlank linesComment linesLines of code
PHP13223200
JavaScript2131557

PHP code Passed 2 tests

Cyclomatic complexity and code structure are the fingerprint of 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.29
Average class complexity19.00
▷ Minimum class complexity19.00
▷ Maximum class complexity19.00
Average method complexity2.20
▷ Minimum method complexity1.00
▷ Maximum method complexity7.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes1
▷ Abstract classes00.00%
▷ Concrete classes1100.00%
▷ Final classes00.00%
Methods15
▷ Static methods533.33%
▷ Public methods15100.00%
▷ Protected methods00.00%
▷ Private methods00.00%
Functions0
▷ Named functions00.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
3 PNG files occupy 0.17MB with 0.09MB in potential savings
Potential savings
Compression of 3 random PNG files using pngquant
FileSize - originalSize - compressedSavings
screenshot-1.png95.91KB34.99KB▼ 63.52%
bg.png1.83KB1.21KB▼ 33.53%
screenshot-2.png78.58KB28.89KB▼ 63.24%