78% serviceform-pixel

Code Review | Serviceform Pixel

WordPress plugin Serviceform Pixel scored78%from 54 tests.

About plugin

  • Plugin page: serviceform-pixel
  • Plugin version: 1.0.0
  • PHP compatiblity: 5.6+
  • PHP version: 7.4.16
  • WordPress compatibility: 5.1-6.3
  • WordPress version: 6.3.1
  • First release: Oct 28, 2020
  • Latest release: Jul 28, 2023
  • Number of updates: 11
  • Update frequency: every 91.3 days
  • Top authors: kaveenm (100%)

Code review

54 tests

User reviews

1 review

Install metrics

400+ active /1,814 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.03MB] [CPU: ▼5.40ms] Passed 4 tests

This is a short check of server-side resources used by Serviceform Pixel
This plugin has minimal impact on server resources
PageMemory (MB)CPU Time (ms)
Home /3.49 ▲0.0338.47 ▼2.17
Dashboard /wp-admin3.34 ▲0.0444.28 ▼2.83
Posts /wp-admin/edit.php3.39 ▲0.0446.24 ▼0.37
Add New Post /wp-admin/post-new.php5.92 ▲0.0481.32 ▼16.23
Media Library /wp-admin/upload.php3.26 ▲0.0437.66 ▲2.02
Settings /wp-admin/admin.php?page=serviceform-pixel-settings3.2231.51
Serviceform /wp-admin/admin.php?page=serviceform-pixel/class-serviceform-pixel-settings.php3.2230.97

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

Filesystem and database footprint
This plugin was installed successfully
Filesystem: 8 new files
Database: no new tables, 6 new options
New WordPress options
can_compress_scripts
widget_recent-posts
widget_theysaidso_widget
theysaidso_admin_options
db_upgraded
widget_recent-comments

Browser metrics Passed 4 tests

A check of browser resources used by Serviceform Pixel
This plugin renders optimally with no browser resource issues detected
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,822 ▲8713.60 ▼0.781.48 ▼0.4342.28 ▼2.34
Dashboard /wp-admin2,231 ▲465.85 ▼0.02103.31 ▼14.6270.32 ▲22.88
Posts /wp-admin/edit.php2,108 ▲192.02 ▲0.0134.19 ▼0.2831.84 ▼2.05
Add New Post /wp-admin/post-new.php1,533 ▼017.56 ▼5.60715.75 ▲32.8262.15 ▲4.18
Media Library /wp-admin/upload.php1,404 ▲224.19 ▼0.02101.29 ▼1.1747.49 ▲3.64
Settings /wp-admin/admin.php?page=serviceform-pixel-settings8202.0227.0631.80
Serviceform /wp-admin/admin.php?page=serviceform-pixel/class-serviceform-pixel-settings.php8202.0525.0325.57

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
  • The uninstall procedure has failed, leaving 6 options in the database
    • db_upgraded
    • widget_recent-comments
    • can_compress_scripts
    • widget_recent-posts
    • theysaidso_admin_options
    • widget_theysaidso_widget

Smoke tests 50% from 4 tests

Server-side errors 0% from 1 test

🔹 Test weight: 20 | A shallow check that no server-side errors were triggered
Smoke test failed, please fix the following
  • 2 occurences, only the last one shown
    • > GET request to /wp-admin/admin.php?page=serviceform-pixel/class-serviceform-pixel-settings.php
    • > Notice in wp-content/plugins/serviceform-pixel/class-serviceform-pixel-settings.php+238
    Undefined index: post_id

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
The following issues need your attention
  • 2× GET requests to PHP files have triggered server-side errors or warnings:
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_action() in wp-content/plugins/serviceform-pixel/class-serviceform-pixel-settings.php:376
    • > PHP Fatal error
      Uncaught Error: Call to undefined function settings_errors() in wp-content/plugins/serviceform-pixel/pages/serviceform-pixel-settings.php:19

User-side errors Passed 1 test

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

Optimizations

Plugin configuration 96% from 29 tests

readme.txt Passed 16 tests

The readme.txt file is an important file in your plugin as it is parsed by WordPress.org to prepare the public listing of your plugin
3 plugin tags: serviceform, bot, chatbot

serviceform-pixel/class-serviceform-pixel-settings.php 92% from 13 tests

The main PHP script in "Serviceform Pixel" version 1.0.0 is automatically included on every request by WordPress
Please take the time to fix the following:
  • Main file name: Even though not officially enforced, the main plugin file should be the same as the plugin slug ("serviceform-pixel.php" instead of "class-serviceform-pixel-settings.php")

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
No dangerous file extensions were detected164 lines of code in 2 files:
LanguageFilesBlank linesComment linesLines of code
PHP241200164

PHP code Passed 2 tests

This is a short overview of cyclomatic complexity and code structure for this plugin
This plugin has no cyclomatic complexity issues
Cyclomatic complexity
Average complexity per logical line of code0.16
Average class complexity9.00
▷ Minimum class complexity9.00
▷ Maximum class complexity9.00
Average method complexity1.57
▷ Minimum method complexity1.00
▷ Maximum method complexity4.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes1
▷ Abstract classes00.00%
▷ Concrete classes1100.00%
▷ Final classes00.00%
Methods14
▷ Static methods214.29%
▷ Public methods1071.43%
▷ Protected methods321.43%
▷ Private methods17.14%
Functions0
▷ Named functions00.00%
▷ Anonymous functions00.00%
Constants2
▷ Global constants00.00%
▷ Class constants2100.00%
▷ Public constants2100.00%

Plugin size Passed 2 tests

Image compression Passed 2 tests

All PNG images should be compressed to minimize bandwidth usage for end users
3 PNG files occupy 0.31MB with 0.14MB in potential savings
Potential savings
Compression of 3 random PNG files using pngquant
FileSize - originalSize - compressedSavings
img/logo24.png1.40KB1.13KB▼ 19.11%
img/logo-mini.png14.20KB6.09KB▼ 57.11%
assets/screenshot-1.png298.97KB119.29KB▼ 60.10%