94% copyright-shortcodes

Code Review | Copyright Shortcodes

WordPress plugin Copyright Shortcodes scored 94% from 54 tests.

About plugin

  • Plugin page: copyright-shortcodes
  • Plugin version: 1.0.1
  • PHP version: 7.4.16
  • WordPress compatibility: 3.0-4.1
  • WordPress version: 5.8.1
  • First release: Sep 15, 2014
  • Latest release: Nov 7, 2014
  • Number of updates: 7
  • Update frequency: every 8.2 days
  • Top authors: mirkolofio (100%)

Code review

54 tests

User reviews

1 review

Install metrics

60+ active / 1,234 total downloads

Benchmarks

Plugin footprint Passed 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | Checking the installer triggered no errors
The plugin installed gracefully, with no errors

Server metrics [RAM: ▲0.00MB] [CPU: ▼140.42ms] Passed 4 tests

This is a short check of server-side resources used by Copyright Shortcodes
No issues were detected with server-side resource usage
PageMemory (MB)CPU Time (ms)
Home /2.84 ▲0.1224.19 ▲5.16
Dashboard /wp-admin3.07 ▲0.0139.64 ▼3.70
Posts /wp-admin/edit.php3.12 ▲0.0147.04 ▲6.31
Add New Post /wp-admin/post-new.php5.43 ▼0.0188.97 ▼565.80
Media Library /wp-admin/upload.php3.01 ▲0.0133.26 ▲2.65

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

A short overview of filesystem and database impact
The plugin installed successfully
Filesystem: 2 new files
Database: no new tables, no new options

Browser metrics Passed 4 tests

A check of browser resources used by Copyright Shortcodes
This plugin renders optimally with no browser resource issues detected
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /3,703 ▲10716.21 ▲0.6710.13 ▲0.6741.82 ▼4.57
Dashboard /wp-admin2,967 ▲365.88 ▼0.10148.08 ▲4.70108.77 ▼1.11
Posts /wp-admin/edit.php2,739 ▼02.72 ▲0.0066.25 ▲0.9893.31 ▲1.11
Add New Post /wp-admin/post-new.php1,683 ▼018.55 ▼0.18371.19 ▼0.95114.14 ▲4.21
Media Library /wp-admin/upload.php1,807 ▼35.04 ▲0.02151.48 ▲0.38121.03 ▲11.84

Uninstaller [IO: ▲0.00MB] [DB: ▲0.00MB] Passed 4 tests

🔸 Tests weight: 35 | Checking the uninstaller removed all traces of the plugin
This plugin's uninstaller ran successfully

Smoke tests 75% from 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | A smoke test targeting server-side errors
Even though everything seems fine, this is not 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
Almost there! Just fix the following items
  • 1× GET requests to PHP files trigger server-side errors or Error 500 responses:
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_shortcode() in wp-content/plugins/copyright-shortcodes/plugin.php:51

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, but this is not an exhaustive test

Optimizations

Plugin configuration 96% from 29 tests

readme.txt Passed 16 tests

It's important to format your readme.txt file correctly as it is parsed for the public listing of your plugin
5 plugin tags: date, shortcode, plugin, copyright, year

copyright-shortcodes/plugin.php 92% from 13 tests

"Copyright Shortcodes" version 1.0.1's primary PHP file adds more information about the plugin and serves as the entry point for WordPress
Please make the necessary changes and fix the following:
  • Main file name: Even though not officially enforced, the main plugin file should be the same as the plugin slug ("copyright-shortcodes.php" instead of "plugin.php")

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | This is an overview of file extensions present in this plugin and a short test that no dangerous files are bundled with this plugin
Everything looks great! No dangerous files found in this plugin56 lines of code in 1 file:
LanguageFilesBlank linesComment linesLines of code
PHP1183256

PHP code Passed 2 tests

This is a short overview of cyclomatic complexity and code structure for this plugin
No cyclomatic complexity issues were detected for this plugin
Cyclomatic complexity
Average complexity per logical line of code0.36
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%
Functions4
▷ Named functions4100.00%
▷ Anonymous functions00.00%
Constants0
▷ Global constants00.00%
▷ Class constants00.00%
▷ Public constants00.00%

Plugin size Passed 2 tests

Image compression Passed 2 tests

Often times overlooked, PNG files can occupy unnecessary space in your plugin
No PNG files were detected