72% start-a-fire

Code Review | Start A Fire

WordPress plugin Start A Fire scored72%from 54 tests.

About plugin

  • Plugin page: start-a-fire
  • Plugin version: 1.0.2
  • PHP version: 7.4.16
  • WordPress compatibility: 4.0-4.5.3
  • WordPress version: 6.3.1
  • First release: Jul 28, 2016
  • Latest release: Jul 31, 2016
  • Number of updates: 7
  • Update frequency: every 0.6 days
  • Top authors: startafirecom (100%)

Code review

54 tests

User reviews

1 review

Install metrics

10+ active /1,316 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.71MB] [CPU: ▲27.50ms] Passed 4 tests

A check of server-side resources used by Start A Fire
This plugin has minimal impact on server resources
PageMemory (MB)CPU Time (ms)
Home /3.56 ▲0.1046.77 ▲0.81
Dashboard /wp-admin3.16 ▼0.1599.15 ▲43.25
Posts /wp-admin/edit.php3.30 ▼0.06107.94 ▲59.77
Add New Post /wp-admin/post-new.php3.25 ▼2.64102.45 ▲6.16
Media Library /wp-admin/upload.php3.24 ▲0.01106.18 ▲64.41
Start A Fire /wp-admin/options-general.php?page=startafire-settings-menu3.1492.14

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

Input-output and database impact of this plugin
This plugin was installed successfully
Filesystem: 6 new files
Database: no new tables, 9 new options
New WordPress options
can_compress_scripts
db_upgraded
theysaidso_admin_options
widget_theysaidso_widget
saf_token
saf_first_activation
saf_links_changed_in_posts
widget_recent-posts
widget_recent-comments

Browser metrics Passed 4 tests

Checking browser requirements for Start A Fire
Normal browser usage
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,806 ▲6013.62 ▼0.612.05 ▼0.3045.15 ▲3.10
Dashboard /wp-admin2,209 ▲214.86 ▼0.04107.27 ▲6.5942.90 ▲2.28
Posts /wp-admin/edit.php2,095 ▲32.04 ▲0.0237.93 ▼2.5536.51 ▼4.59
Add New Post /wp-admin/post-new.php1,538 ▲523.28 ▲0.08675.37 ▼35.6156.89 ▲4.10
Media Library /wp-admin/upload.php1,397 ▲64.23 ▲0.0198.35 ▼7.4447.19 ▼2.42
Start A Fire /wp-admin/options-general.php?page=startafire-settings-menu7972.2627.5728.32

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

🔸 Tests weight: 35 | Checking the uninstaller removed all traces of the plugin
The following items require your attention
  • This plugin does not fully uninstall, leaving 6 options in the database
    • can_compress_scripts
    • widget_theysaidso_widget
    • theysaidso_admin_options
    • widget_recent-posts
    • db_upgraded
    • widget_recent-comments

Smoke tests 25% from 4 tests

Server-side errors 0% from 1 test

🔹 Test weight: 20 | This is a short smoke test looking for server-side errors
These server-side errors were triggered
  • 5 occurences, only the last one shown
    • > GET request to /wp-admin/options-general.php?page=startafire-settings-menu
    • > Notice in wp-content/plugins/start-a-fire/saf-main.php+274
    Trying to access array offset on value of type null
  • 2 occurences, only the last one shown
    • > GET request to /wp-admin/options-general.php?page=startafire-settings-menu
    • > User notice in wp-includes/functions.php+5905
    Function WP_Scripts::localize was called incorrectly. The $l10n parameter must be an array. To pass arbitrary data to scripts, use the wp_add_inline_script() function instead. Please see Debugging in WordPress for more information. (This message was added in version 5.7.0.)

SRP 50% from 2 tests

🔹 Tests weight: 20 | The single-responsibility principle: PHP files have to remain inert when accessed directly, throwing no errors and performing no actions
Please fix the following
  • 2× 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/start-a-fire/saf-main.php:69
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_action() in wp-content/plugins/start-a-fire/saf-main.php:69

User-side errors 0% from 1 test

🔹 Test weight: 20 | A shallow check that no browser errors were triggered
Please fix the following user-side errors
    • > GET request to /wp-admin/options-general.php?page=startafire-settings-menu
    • > Javascript (severe) in unknown
    /wp-admin/options-general.php?page=startafire-settings-menu - Access to XMLHttpRequest at 'https://api.startafire.com/user/getexcludeddomains?access_token=' from origin '' has been blocked by CORS policy: No 'Access-Control-Allow-Origin' header is present on the requested resource.
    • > GET request to /wp-admin/options-general.php?page=startafire-settings-menu
    • > Network (severe)
    https://api.startafire.com/user/getexcludeddomains?access_token= - Failed to load resource: net::ERR_FAILED

Optimizations

Plugin configuration 96% from 29 tests

readme.txt Passed 16 tests

Don't ignore readme.txt as it is the file that instructs WordPress.org on how to present your plugin to the world
9 plugin tags: start a fire, marketing, share, marketing automation, links...

start-a-fire/saf-trigger.php 92% from 13 tests

The main file in "Start A Fire" v. 1.0.2 serves as a complement to information provided in readme.txt and as the entry point to the plugin
It is important to fix the following:
  • Main file name: The principal plugin file should be the same as the plugin slug ("start-a-fire.php" instead of "saf-trigger.php")

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | This is an overview of file extensions present in this plugin and a short test that no dangerous files are bundled with this plugin
Everything looks great! No dangerous files found in this plugin1,076 lines of code in 5 files:
LanguageFilesBlank linesComment linesLines of code
PHP2133146674
CSS15314233
JavaScript22324169

PHP code Passed 2 tests

A brief analysis of cyclomatic complexity and code structure for this plugin
There were no cyclomatic complexity issued detected
Cyclomatic complexity
Average complexity per logical line of code0.26
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%
Functions31
▷ Named functions2993.55%
▷ Anonymous functions26.45%
Constants1
▷ Global constants1100.00%
▷ Class constants00.00%
▷ Public constants00.00%

Plugin size Passed 2 tests

Image compression Passed 2 tests

Often times overlooked, PNG files can occupy unnecessary space in your plugin
PNG images were not found in this plugin