83% aistore-incidents-updates

Code Review | Aistore incident reportings

WordPress plugin Aistore incident reportings scored83%from 54 tests.

About plugin

  • Plugin page: aistore-incidents...
  • Plugin version: 4.1.1
  • PHP version: 7.4.16
  • WordPress version: 6.3.1
  • First release: Jan 23, 2020
  • Latest release: Jan 26, 2020
  • Number of updates: 3
  • Update frequency: every 1.3 days
  • Top authors: susheelhbti (100%)

Code review

54 tests

User reviews

1 review

Install metrics

10+ active /452 total downloads

Benchmarks

Plugin footprint 83% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | The install procedure must perform silently
This plugin's installer ran successfully

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

A check of server-side resources used by Aistore incident reportings
This plugin does not affect your website's performance
PageMemory (MB)CPU Time (ms)
Home /3.49 ▲0.0338.12 ▲0.34
Dashboard /wp-admin3.32 ▼0.0252.99 ▼3.28
Posts /wp-admin/edit.php3.38 ▲0.0246.55 ▼1.65
Add New Post /wp-admin/post-new.php5.96 ▲0.0884.65 ▼3.88
Media Library /wp-admin/upload.php3.25 ▲0.0234.12 ▲2.77
Add New /wp-admin/post-new.php?post_type=incident5.9586.56
All Incidents /wp-admin/edit.php?post_type=incident3.2936.48

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

How much does this plugin use your filesystem and database?
There were no storage issued detected upon installing this plugin
Filesystem: 2 new files
Database: no new tables, 6 new options
New WordPress options
widget_recent-comments
widget_recent-posts
widget_theysaidso_widget
can_compress_scripts
db_upgraded
theysaidso_admin_options

Browser metrics Passed 4 tests

Aistore incident reportings: an overview of browser usage
Minimal impact on browser resources
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,819 ▲6914.41 ▲0.061.81 ▲0.2644.22 ▲2.18
Dashboard /wp-admin2,222 ▲545.50 ▼0.0381.76 ▼3.9539.90 ▼2.48
Posts /wp-admin/edit.php2,127 ▲272.00 ▼0.0234.27 ▼0.7736.93 ▲2.24
Add New Post /wp-admin/post-new.php1,549 ▲2123.05 ▼0.17662.72 ▲17.4557.00 ▼0.75
Media Library /wp-admin/upload.php1,421 ▲274.32 ▲0.14101.67 ▼2.9845.48 ▲0.92
Add New /wp-admin/post-new.php?post_type=incident6,18722.89845.9827.30
All Incidents /wp-admin/edit.php?post_type=incident1,1001.9834.7332.65

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

🔸 Tests weight: 35 | Verifying that this plugin uninstalls completely without leaving any traces
The following items require your attention
  • This plugin does not fully uninstall, leaving 6 options in the database
    • widget_theysaidso_widget
    • db_upgraded
    • widget_recent-posts
    • theysaidso_admin_options
    • can_compress_scripts
    • widget_recent-comments

Smoke tests 75% from 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | Just a short smoke test targeting errors on the server (in the Apache logs)
Even though no errors were found, this is by no means an exhaustive test

SRP 50% 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
The following issues need your attention
  • 1× PHP files trigger errors when accessed directly with GET requests:
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_action() in wp-content/plugins/aistore-incidents-updates/index.php:76

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 90% from 29 tests

readme.txt 94% from 16 tests

It's important to format your readme.txt file correctly as it is parsed for the public listing of your plugin
Attributes that require attention:
  • Requires at least: Invalid version format
You can take inspiration from this readme.txt

aistore-incidents-updates/index.php 85% from 13 tests

The main PHP file in "Aistore incident reportings" ver. 4.1.1 adds more information about the plugin and also serves as the entry point for this plugin
You should first fix the following items:
  • Main file name: Even though not officially enforced, the main plugin file should be the same as the plugin slug ("aistore-incidents-updates.php" instead of "index.php")
  • Description: If Twitter did it, so should we! Keep the description under 140 characters (currently 193 characters long)

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | A short glimpse at programming languages used with this plugin and a check that no dangerous files are present
Everything looks great! No dangerous files found in this plugin75 lines of code in 1 file:
LanguageFilesBlank linesComment linesLines of code
PHP118975

PHP code Passed 2 tests

An short overview of logical lines of code, cyclomatic complexity, and other code metrics
There were no cyclomatic complexity issued detected
Cyclomatic complexity
Average complexity per logical line of code0.08
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%
Functions2
▷ Named functions2100.00%
▷ Anonymous functions00.00%
Constants0
▷ Global constants00.00%
▷ Class constants00.00%
▷ Public constants00.00%

Plugin size Passed 2 tests

Image compression Passed 2 tests

PNG files should be compressed to save space and minimize bandwidth usage
No PNG files were detected