78% cryptocurrency-shortcode

Code Review | Crypto-Currency Shortcode

WordPress plugin Crypto-Currency Shortcode scored78%from 54 tests.

About plugin

  • Plugin page: cryptocurrency-sh...
  • Plugin version: 1.4
  • PHP version: 7.4.16
  • WordPress compatibility: 3.0-3.9.1
  • WordPress version: 6.3.1
  • First release: Mar 5, 2014
  • Latest release: May 25, 2014
  • Number of updates: 32
  • Update frequency: every 2.6 days
  • Top authors: KAZApocrypha (100%)

Code review

54 tests

User reviews

1 review

Install metrics

10+ active /5,967 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
This plugin's installer ran successfully

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

Server-side resources used by Crypto-Currency Shortcode
This plugin has minimal impact on server resources
PageMemory (MB)CPU Time (ms)
Home /3.47 ▲0.0144.99 ▲4.77
Dashboard /wp-admin3.32 ▲0.0247.50 ▼6.13
Posts /wp-admin/edit.php3.37 ▲0.0152.01 ▼5.08
Add New Post /wp-admin/post-new.php5.90 ▲0.0187.49 ▼17.19
Media Library /wp-admin/upload.php3.24 ▲0.0137.59 ▲1.68

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

A short overview of filesystem and database impact
This plugin was installed successfully
Filesystem: 35 new files
Database: no new tables, 6 new options
New WordPress options
widget_recent-posts
widget_recent-comments
can_compress_scripts
widget_theysaidso_widget
theysaidso_admin_options
db_upgraded

Browser metrics Passed 4 tests

An overview of browser requirements for Crypto-Currency Shortcode
This plugin renders optimally with no browser resource issues detected
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,874 ▲11313.86 ▼0.588.36 ▲6.6144.40 ▲4.38
Dashboard /wp-admin2,197 ▲205.62 ▼0.03105.39 ▼1.1545.52 ▼2.68
Posts /wp-admin/edit.php2,102 ▼11.99 ▲0.0340.38 ▼1.4135.29 ▼2.72
Add New Post /wp-admin/post-new.php1,552 ▲2623.01 ▼0.08664.30 ▼16.2859.18 ▲1.26
Media Library /wp-admin/upload.php1,402 ▲54.22 ▲0.0596.66 ▼1.2241.37 ▼4.62

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
It is recommended to fix the following
  • This plugin does not fully uninstall, leaving 6 options in the database
    • can_compress_scripts
    • widget_recent-comments
    • db_upgraded
    • widget_recent-posts
    • theysaidso_admin_options
    • widget_theysaidso_widget

Smoke tests 50% from 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | This is a short smoke test looking for server-side errors
Even though everything seems fine, this is not an exhaustive test

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 output non-empty strings when accessed directly via GET requests:
    • > /wp-content/plugins/cryptocurrency-shortcode/coin_js_wrapper.php
  • 1× PHP files trigger server-side errors or warnings when accessed directly:
    • > PHP Fatal error
      Uncaught Error: Call to undefined function trailingslashit() in wp-content/plugins/cryptocurrency-shortcode/cryptocurrency-shortcode.php:16

User-side errors Passed 1 test

🔹 Test weight: 20 | This is a shallow check for browser errors
There were no browser issues found

Optimizations

Plugin configuration 96% from 29 tests

readme.txt Passed 16 tests

You should put a lot of thought into formatting readme.txt as it is used by WordPress.org to prepare the public listing of your plugin
7 plugin tags: litecoin, kumacoin, ringo, coinwidget, dogecoin...

cryptocurrency-shortcode/cryptocurrency-shortcode.php 92% from 13 tests

The main PHP script in "Crypto-Currency Shortcode" version 1.4 is automatically included on every request by WordPress
The following require your attention:
  • Description: 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 considered dangerous and should not be included with any WordPress plugin
Success! There were no dangerous files found in this plugin2,767 lines of code in 21 files:
LanguageFilesBlank linesComment linesLines of code
PHP176095172,378
JavaScript11535288
CSS1143053
Markdown122027
HTML1112421

PHP code Passed 2 tests

Analyzing logical lines of code, cyclomatic complexity, and other code metrics
This plugin has no cyclomatic complexity issues
Cyclomatic complexity
Average complexity per logical line of code0.32
Average class complexity22.82
▷ Minimum class complexity1.00
▷ Maximum class complexity69.00
Average method complexity3.71
▷ Minimum method complexity1.00
▷ Maximum method complexity19.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes17
▷ Abstract classes00.00%
▷ Concrete classes17100.00%
▷ Final classes00.00%
Methods137
▷ Static methods6144.53%
▷ Public methods13598.54%
▷ Protected methods00.00%
▷ Private methods21.46%
Functions8
▷ Named functions8100.00%
▷ Anonymous functions00.00%
Constants32
▷ Global constants32100.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
8 PNG files occupy 0.01MB with 0.00MB in potential savings
Potential savings
Compression of 5 random PNG files using pngquant
FileSize - originalSize - compressedSavings
coinwidget.com/icon_wallet.png0.62KB0.60KB▼ 3.13%
coinwidget.com/icon_kumacoin.png0.89KB0.96KB0.00%
coinwidget.com/icon_ringo.png0.49KB0.19KB▼ 61.72%
coinwidget.com/icon_litecoin.png1.67KB0.78KB▼ 53.54%
coinwidget.com/icon_bitcoin.png1.78KB1.05KB▼ 40.82%