94% plugin-info-cards

Code Review | Plugin Info Cards

WordPress plugin Plugin Info Cards scored 94% from 54 tests.

About plugin

  • Plugin page: plugin-info-cards
  • Plugin version: 1.0
  • PHP version: 7.4.16
  • WordPress compatibility: 4.1-5.1
  • WordPress version: 5.8.1
  • First release: Sep 11, 2017
  • Latest release: Feb 27, 2019
  • Number of updates: 3
  • Update frequency: every 178.4 days
  • Top authors: gagan0123 (100%)

Code review

54 tests

User reviews

1 review

Install metrics

10+ active / 2,286 total downloads

Benchmarks

Plugin footprint Passed 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | Checking the installer triggered no errors
Installer ran successfully

Server metrics [RAM: ▲0.07MB] [CPU: ▼147.67ms] Passed 4 tests

An overview of server-side resources used by Plugin Info Cards
No issues were detected with server-side resource usage
PageMemory (MB)CPU Time (ms)
Home /2.91 ▲0.0835.94 ▲1.45
Dashboard /wp-admin3.13 ▲0.0846.31 ▼4.12
Posts /wp-admin/edit.php3.18 ▲0.0845.80 ▼5.06
Add New Post /wp-admin/post-new.php5.49 ▲0.06100.70 ▼573.17
Media Library /wp-admin/upload.php3.07 ▲0.0735.65 ▼8.33

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

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

Browser metrics Passed 4 tests

Plugin Info Cards: an overview of browser usage
There were no issues detected in relation to browser resource usage
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /3,705 ▲13315.94 ▲0.179.57 ▼4.6249.91 ▲2.07
Dashboard /wp-admin2,967 ▲365.92 ▼0.03148.08 ▼2.34111.83 ▲0.32
Posts /wp-admin/edit.php2,739 ▼02.70 ▼0.0275.12 ▲6.2883.18 ▼11.69
Add New Post /wp-admin/post-new.php1,683 ▼018.74 ▼0.02422.03 ▼0.93108.02 ▼2.02
Media Library /wp-admin/upload.php1,807 ▼05.03 ▼0.02168.28 ▲2.25116.51 ▼6.95

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

🔸 Tests weight: 35 | All plugins must uninstall correctly, removing their source code and extra database tables they might have created
The plugin uninstalled completely, with no zombie files or tables

Smoke tests 75% from 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | A smoke test targeting server-side errors
Good news, no errors were detected

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 take a closer look at the following
  • 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/plugin-info-cards/includes/class-plugin-info-cards.php:41

User-side errors Passed 1 test

🔹 Test weight: 20 | This is a smoke test targeting browser errors/issues
No browser errors were detected

Optimizations

Plugin configuration Passed 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
3 plugin tags: info, cards, plugin

plugin-info-cards/plugin-info-cards.php Passed 13 tests

"Plugin Info Cards" version 1.0's main PHP file describes plugin functionality and also serves as the entry point to any WordPress functionality
53 characters long description:
Adds shortcode to display plugin info for given slugs

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | There should be no dangerous file extensions present in any WordPress plugin
No dangerous file extensions were detected535 lines of code in 7 files:
LanguageFilesBlank linesComment linesLines of code
PHP458305353
Sass2330181
CSS1011

PHP code Passed 2 tests

An overview of cyclomatic complexity and code structure
All good! No complexity issues found
Cyclomatic complexity
Average complexity per logical line of code0.37
Average class complexity19.00
▷ Minimum class complexity18.00
▷ Maximum class complexity20.00
Average method complexity4.27
▷ Minimum method complexity1.00
▷ Maximum method complexity11.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes2
▷ Abstract classes00.00%
▷ Concrete classes2100.00%
▷ Final classes00.00%
Methods11
▷ Static methods19.09%
▷ Public methods981.82%
▷ Protected methods00.00%
▷ Private methods218.18%
Functions0
▷ Named functions00.00%
▷ Anonymous functions00.00%
Constants2
▷ Global constants2100.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
PNG images were not found in this plugin