83% credly-pro-custom-assertion

Code Review | Credly Custom Badge Assertion Shortcode

WordPress plugin Credly Custom Badge Assertion Shortcode scored83%from 54 tests.

About plugin

  • Plugin page: credly-pro-custom...
  • Plugin version: 1.0.0
  • PHP version: 7.4.16
  • WordPress compatibility: 3.5-3.7.0
  • WordPress version: 6.3.1
  • First release: Dec 4, 2013
  • Latest release: May 19, 2016
  • Number of updates: 4
  • Update frequency: every 226.2 days
  • Top authors: credly (75%)tw2113 (50%)

Code review

54 tests

User reviews

1 review

Install metrics

10+ active /1,442 total downloads

Benchmarks

Plugin footprint 83% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | The install procedure must perform silently
Installer ran successfully

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

Server-side resources used by Credly Custom Badge Assertion Shortcode
Server-side resource usage in normal parameters
PageMemory (MB)CPU Time (ms)
Home /3.47 ▲0.0038.03 ▲0.61
Dashboard /wp-admin3.31 ▼0.0344.81 ▼13.91
Posts /wp-admin/edit.php3.37 ▲0.0049.04 ▼0.29
Add New Post /wp-admin/post-new.php5.90 ▲0.0082.85 ▼18.84
Media Library /wp-admin/upload.php3.24 ▲0.0034.18 ▲3.11

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

Analyzing filesystem and database footprints of this plugin
There were no storage issued detected upon installing this plugin
Filesystem: 3 new files
Database: no new tables, 6 new options
New WordPress options
can_compress_scripts
theysaidso_admin_options
widget_recent-comments
widget_recent-posts
db_upgraded
widget_theysaidso_widget

Browser metrics Passed 4 tests

This is an overview of browser requirements for Credly Custom Badge Assertion Shortcode
There were no issues detected in relation to browser resource usage
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,789 ▲314.28 ▼0.291.70 ▼0.4847.46 ▲3.86
Dashboard /wp-admin2,195 ▲185.61 ▲0.0788.79 ▼2.5237.21 ▼4.82
Posts /wp-admin/edit.php2,100 ▼02.01 ▼0.0139.99 ▲4.8038.03 ▲2.69
Add New Post /wp-admin/post-new.php1,526 ▼1322.77 ▼0.28600.64 ▼62.3170.33 ▲14.54
Media Library /wp-admin/upload.php1,394 ▼64.17 ▼0.0994.21 ▼8.3140.97 ▼4.38

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

🔸 Tests weight: 35 | The uninstall procedure must remove all plugin files and extra database tables
These items require your attention
  • Zombie WordPress options detected upon uninstall: 6 options
    • theysaidso_admin_options
    • can_compress_scripts
    • widget_theysaidso_widget
    • db_upgraded
    • widget_recent-comments
    • widget_recent-posts

Smoke tests 75% from 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | This is a short smoke test looking for server-side errors
Everything seems fine, however this is by no means an exhaustive test

SRP 50% from 2 tests

🔹 Tests weight: 20 | A shallow check of the single-responsibility principle; PHP files should perform no action - including output of placeholder text - and trigger no errors when accessed directly
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_shortcode() in wp-content/plugins/credly-pro-custom-assertion/credly-badge-assertion.php:55

User-side errors Passed 1 test

🔹 Test weight: 20 | A shallow check that no browser errors were triggered
There were no browser issues found

Optimizations

Plugin configuration 87% from 29 tests

readme.txt 88% from 16 tests

The readme.txt file is important because it is parsed by WordPress.org for the public listing of your plugin
Please fix the following attributes:
  • Screenshots: Add a description for screenshot #3 in credly-pro-custom-assertion/assets to your readme.txt
  • Tags: Please delete some tags, you are using 17 tag instead of maximum 10
You can look at the official readme.txt

credly-pro-custom-assertion/credly-badge-assertion.php 85% from 13 tests

The primary PHP file in "Credly Custom Badge Assertion Shortcode" version 1.0.0 is used by WordPress to initiate all plugin functionality
You should first fix the following items:
  • Description: If Twitter did it, so should we! Keep the description under 140 characters (currently 374 characters long)
  • Main file name: The principal plugin file should be the same as the plugin slug ("credly-pro-custom-assertion.php" instead of "credly-badge-assertion.php")

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | This is an overview of programming languages used in this plugin; dangerous file extensions are not allowed
Success! There were no dangerous files found in this plugin15 lines of code in 1 file:
LanguageFilesBlank linesComment linesLines of code
PHP193115

PHP code Passed 2 tests

An overview of cyclomatic complexity and code structure
Great job! No cyclomatic complexity issues were detected in this plugin
Cyclomatic complexity
Average complexity per logical line of code0.50
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%
Functions1
▷ Named functions1100.00%
▷ Anonymous functions00.00%
Constants0
▷ Global constants00.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
PNG images were not found in this plugin