90% sparki

Code Review | Sparki

WordPress plugin Sparki scored 90% from 54 tests.

About plugin

  • Plugin page: sparki
  • Plugin version: 1.0.0
  • PHP compatiblity: 5.6+
  • PHP version: 7.4.16
  • WordPress compatibility: 3.0.1-6.0
  • WordPress version: 6.3.1
  • First release: Aug 18, 2022
  • Latest release: Aug 26, 2022
  • Number of updates: 4
  • Update frequency: every 4.3 days
  • Top authors: sparkiapp (100%)

Code review

54 tests

User reviews

1 review

Install metrics

10+ active / 144 total downloads

Benchmarks

Plugin footprint 83% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | All plugins must install correctly, without throwing any errors, warnings, or notices
The plugin installed gracefully, with no errors

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

This is a short check of server-side resources used by Sparki
Server-side resource usage in normal parameters
PageMemory (MB)CPU Time (ms)
Home /3.51 ▲0.0521.78 ▼16.48
Dashboard /wp-admin3.38 ▲0.0744.47 ▼8.43
Posts /wp-admin/edit.php3.49 ▲0.1344.12 ▼2.36
Add New Post /wp-admin/post-new.php5.96 ▲0.0782.90 ▼14.27
Media Library /wp-admin/upload.php3.30 ▲0.0735.20 ▲1.68

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

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

Browser metrics Passed 4 tests

Checking browser requirements for Sparki
Normal browser usage
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /3,035 ▲30016.11 ▲1.7681.94 ▲80.1937.22 ▼4.36
Dashboard /wp-admin2,227 ▲354.82 ▼0.11102.12 ▼2.2436.37 ▼4.10
Posts /wp-admin/edit.php2,104 ▲182.05 ▼0.0033.86 ▼0.0632.07 ▼2.49
Add New Post /wp-admin/post-new.php1,543 ▲2423.49 ▲0.12656.52 ▼62.5761.34 ▲10.74
Media Library /wp-admin/upload.php1,409 ▲274.20 ▼0.0199.00 ▼4.4544.55 ▲1.06

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

🔸 Tests weight: 35 | Checking the uninstaller removed all traces of the plugin
You still need to fix the following
  • This plugin does not fully uninstall, leaving 6 options in the database
    • can_compress_scripts
    • db_upgraded
    • widget_theysaidso_widget
    • theysaidso_admin_options
    • widget_recent-comments
    • widget_recent-posts

Smoke tests Passed 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | A shallow check that no server-side errors were triggered
The smoke test was a success, however most plugin functionality was not tested

SRP Passed 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
Everything seems fine, however this is by no means an exhaustive test

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)
There were no browser issues found

Optimizations

Plugin configuration 96% from 29 tests

readme.txt Passed 16 tests

The readme.txt file is important because it is parsed by WordPress.org for the public listing of your plugin
3 plugin tags: reservations, communication, messages

sparki/sparki.php 92% from 13 tests

This is the main PHP file of "Sparki" version 1.0.0, providing information about the plugin in the header fields and serving as the principal entry point to the plugin's functions
It is important to fix the following:
  • Description: Please keep the plugin description shorter than 140 characters (currently 216 characters long)

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | A short check of programming languages and file extensions; no executable files are allowed
There were no executable files found in this plugin331 lines of code in 11 files:
LanguageFilesBlank linesComment linesLines of code
PHP10133572317
CSS10414

PHP code Passed 2 tests

Analyzing cyclomatic complexity and code structure
Although this was not an exhaustive test, there were no cyclomatic complexity issues detected
Cyclomatic complexity
Average complexity per logical line of code0.12
Average class complexity1.43
▷ Minimum class complexity1.00
▷ Maximum class complexity3.00
Average method complexity1.12
▷ Minimum method complexity1.00
▷ Maximum method complexity3.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes7
▷ Abstract classes00.00%
▷ Concrete classes7100.00%
▷ Final classes00.00%
Methods25
▷ Static methods28.00%
▷ Public methods2080.00%
▷ Protected methods00.00%
▷ Private methods520.00%
Functions9
▷ Named functions9100.00%
▷ Anonymous functions00.00%
Constants1
▷ Global constants1100.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
No PNG images were found in this plugin