84% simple-history-cards

Code Review | Simple History Cards

WordPress plugin Simple History Cards scored84%from 54 tests.

About plugin

  • Plugin page: simple-history-cards
  • Plugin version: 1.0.1
  • PHP version: 7.4.16
  • WordPress compatibility: 3.0-4.6.1
  • WordPress version: 6.3.1
  • First release: Aug 12, 2015
  • Latest release: Sep 27, 2016
  • Number of updates: 5
  • Update frequency: every 82.4 days
  • Top authors: urre (100%)

Code review

54 tests

User reviews

1 review

Install metrics

10+ active /1,096 total downloads

Benchmarks

Plugin footprint 82% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | It is important to correctly install your plugin, without throwing errors or notices
The plugin installed successfully, without throwing any errors or notices

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

Analyzing server-side resources used by Simple History Cards
This plugin does not affect your website's performance
PageMemory (MB)CPU Time (ms)
Home /3.47 ▲0.0141.05 ▼4.06
Dashboard /wp-admin3.31 ▼0.0356.63 ▼10.68
Posts /wp-admin/edit.php3.36 ▲0.0151.16 ▼1.03
Add New Post /wp-admin/post-new.php5.91 ▲0.0399.07 ▼6.18
Media Library /wp-admin/upload.php3.24 ▲0.0141.21 ▲3.50

Server storage [IO: ▲0.15MB] [DB: ▲0.00MB] 67% from 3 tests

Filesystem and database footprint
It is recommended to fix the following issues
  • The plugin illegally modified 1 file (4.00KB) outside of "wp-content/plugins/simple-history-cards/" and "wp-content/uploads/"
    • (new file) wp-content/mgd_mirror/mgd_maximinodotpy-gitdown-test-repository
Filesystem: 6 new files
Database: no new tables, 6 new options
New WordPress options
widget_recent-posts
can_compress_scripts
db_upgraded
widget_theysaidso_widget
theysaidso_admin_options
widget_recent-comments

Browser metrics Passed 4 tests

An overview of browser requirements for Simple History Cards
Minimal impact on browser resources
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,819 ▲5813.67 ▼0.912.27 ▲0.4742.20 ▼2.11
Dashboard /wp-admin2,228 ▲224.89 ▼0.17104.71 ▼7.8739.44 ▼3.96
Posts /wp-admin/edit.php2,104 ▲42.03 ▲0.0340.23 ▲2.4034.19 ▲1.22
Add New Post /wp-admin/post-new.php1,529 ▼217.39 ▼5.69671.96 ▲23.1360.51 ▲10.56
Media Library /wp-admin/upload.php1,407 ▲134.21 ▲0.0499.49 ▲1.0944.46 ▲2.37

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

🔸 Tests weight: 35 | It is important to correctly uninstall your plugin, without leaving any traces
These items require your attention
  • Zombie WordPress options detected upon uninstall: 6 options
    • widget_recent-posts
    • theysaidso_admin_options
    • widget_theysaidso_widget
    • can_compress_scripts
    • db_upgraded
    • widget_recent-comments

Smoke tests 75% from 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | A smoke test targeting server-side errors
The smoke test was a success, however most plugin functionality was not tested

SRP 50% from 2 tests

🔹 Tests weight: 20 | It is important to ensure that your PHP files perform no action when accessed directly, respecting the single-responsibility principle
Please fix the following items
  • 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/simple-history-cards/simple-history-cards.php:34

User-side errors Passed 1 test

🔹 Test weight: 20 | A shallow check that no browser errors were triggered
No browser errors were detected

Optimizations

Plugin configuration 97% from 29 tests

readme.txt 94% from 16 tests

The readme.txt file describes your plugin functionality and requirements and it is parsed to prepare the your plugin's listing
Attributes that need to be fixed:
  • Screenshots: Screenshot #1 (Simple History Cards) image missing
The official readme.txt might help

simple-history-cards/simple-history-cards.php Passed 13 tests

This is the main PHP file of "Simple History Cards" version 1.0.1, providing information about the plugin in the header fields and serving as the principal entry point to the plugin's functions
36 characters long description:
Card based layout for Simple History

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 plugin331 lines of code in 4 files:
LanguageFilesBlank linesComment linesLines of code
CSS1410214
JavaScript1362681
Markdown110020
PHP1142316

PHP code Passed 2 tests

This is a very shot review of cyclomatic complexity and code structure
There were no cyclomatic complexity issued detected
Cyclomatic complexity
Average complexity per logical line of code0.20
Average class complexity2.00
▷ Minimum class complexity2.00
▷ Maximum class complexity2.00
Average method complexity1.33
▷ Minimum method complexity1.00
▷ Maximum method complexity2.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes1
▷ Abstract classes00.00%
▷ Concrete classes1100.00%
▷ Final classes00.00%
Methods3
▷ Static methods00.00%
▷ Public methods3100.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

Using a strong compression for your PNG files is a great way to speed-up your plugin
1 PNG file occupies 0.14MB with 0.08MB in potential savings
Potential savings
Compression of 1 random PNG file using pngquant
FileSize - originalSize - compressedSavings
screenshot-1.png141.70KB56.11KB▼ 60.40%