84% trialfire

Code Review | Trialfire

WordPress plugin Trialfire scored84%from 54 tests.

About plugin

  • Plugin page: trialfire
  • Plugin version: 1.0.0
  • PHP version: 7.4.16
  • WordPress compatibility: 2.7-3.5
  • WordPress version: 6.3.1
  • First release: Jun 17, 2014
  • Latest release: Jun 18, 2014
  • Number of updates: 2
  • Update frequency: every 1.0 days
  • Top authors: kevintrialfire (100%)

Code review

54 tests

User reviews

1 review

Install metrics

20+ active /1,056 total downloads

Benchmarks

Plugin footprint 83% from 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: ▼11.99ms] Passed 4 tests

A check of server-side resources used by Trialfire
This plugin has minimal impact on server resources
PageMemory (MB)CPU Time (ms)
Home /3.47 ▲0.0136.61 ▼9.95
Dashboard /wp-admin3.32 ▼0.0346.88 ▼21.37
Posts /wp-admin/edit.php3.37 ▲0.0150.65 ▼1.27
Add New Post /wp-admin/post-new.php5.90 ▲0.0185.88 ▼15.38
Media Library /wp-admin/upload.php3.24 ▲0.0139.66 ▲2.46
Trialfire /wp-admin/options-general.php?page=trialfire3.2132.50

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

A short overview of filesystem and database impact
No storage issues were detected
Filesystem: 8 new files
Database: no new tables, 7 new options
New WordPress options
can_compress_scripts
db_upgraded
widget_recent-posts
theysaidso_admin_options
widget_recent-comments
widget_theysaidso_widget
tf_snippet

Browser metrics Passed 4 tests

This is an overview of browser requirements for Trialfire
There were no issues detected in relation to browser resource usage
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,797 ▲5114.38 ▲0.261.83 ▼0.1540.75 ▼4.03
Dashboard /wp-admin2,196 ▲165.65 ▼0.0592.68 ▼1.3037.29 ▼7.36
Posts /wp-admin/edit.php2,104 ▲42.01 ▲0.0339.87 ▲2.4534.14 ▼3.44
Add New Post /wp-admin/post-new.php1,548 ▼723.21 ▲4.95668.07 ▲31.1754.38 ▼6.69
Media Library /wp-admin/upload.php1,407 ▲74.14 ▼0.1498.69 ▼7.3344.21 ▼4.40
Trialfire /wp-admin/options-general.php?page=trialfire8472.0426.8433.08

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

🔸 Tests weight: 35 | Checking the uninstaller removed all traces of the plugin
Please fix the following items
  • The uninstall procedure has failed, leaving 6 options in the database
    • db_upgraded
    • can_compress_scripts
    • widget_recent-posts
    • widget_recent-comments
    • widget_theysaidso_widget
    • theysaidso_admin_options

Smoke tests 75% from 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | A shallow check that no server-side errors were triggered
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 fix the following items
  • 2× PHP files trigger server errors when accessed directly:
    • > PHP Fatal error
      Uncaught Error: Call to undefined function wp_nonce_field() in wp-content/plugins/trialfire/options.php:5
    • > PHP Fatal error
      Uncaught Error: Call to undefined function get_option() in wp-content/plugins/trialfire/trialfiresnippet.php:12

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)
No browser errors were detected

Optimizations

Plugin configuration 93% 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
These attributes need your attention:
  • Screenshots: Add images for these screenshots: #1 (Modified settings panel with Trialfire), #2 (Trialfire settings page), #3 (Trialfire settings page with example tracking snippet)
You can take inspiration from this readme.txt

trialfire/trialfiresnippet.php 92% from 13 tests

"Trialfire" version 1.0.0's primary PHP file adds more information about the plugin and serves as the entry point for WordPress
Please take the time to fix the following:
  • Main file name: Please rename the main PHP file in this plugin to the plugin slug ("trialfire.php" instead of "trialfiresnippet.php")

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | This is a short overview of programming languages used in this plugin, detecting executable files
Everything looks great! No dangerous files found in this plugin77 lines of code in 2 files:
LanguageFilesBlank linesComment linesLines of code
PHP223877

PHP code Passed 2 tests

An overview of cyclomatic complexity and code structure
This plugin has no cyclomatic complexity problems
Cyclomatic complexity
Average complexity per logical line of code0.32
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%
Functions6
▷ Named functions6100.00%
▷ Anonymous functions00.00%
Constants4
▷ Global constants4100.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
3 PNG files occupy 0.14MB with 0.10MB in potential savings
Potential savings
Compression of 3 random PNG files using pngquant
FileSize - originalSize - compressedSavings
screenshot-3.png71.79KB21.91KB▼ 69.48%
screenshot-2.png46.75KB13.97KB▼ 70.12%
screenshot-1.png25.03KB6.58KB▼ 73.72%