72% contractor-commerce-integration

Code Review | Contractor Commerce Integration

WordPress plugin Contractor Commerce Integration scored72%from 54 tests.

About plugin

  • Plugin page: contractor-commer...
  • Plugin version: 1.0.2
  • PHP compatiblity: 7.0+
  • PHP version: 7.4.16
  • WordPress compatibility: 3.0.1-6.3
  • WordPress version: 6.3.1
  • First release: Jan 20, 2022
  • Latest release: Aug 11, 2023
  • Number of updates: 6
  • Update frequency: every 94.7 days
  • Top authors: contractorcommerce (100%)

Code review

54 tests

User reviews

1 review

Install metrics

30+ active /480 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
Installer ran successfully

Server metrics [RAM: ▼0.26MB] [CPU: ▼17.30ms] Passed 4 tests

An overview of server-side resources used by Contractor Commerce Integration
This plugin does not affect your website's performance
PageMemory (MB)CPU Time (ms)
Home /3.50 ▲0.0432.58 ▼10.83
Dashboard /wp-admin3.37 ▲0.0747.96 ▼4.19
Posts /wp-admin/edit.php3.48 ▲0.1350.68 ▲1.23
Add New Post /wp-admin/post-new.php4.66 ▼1.2347.08 ▼55.42
Media Library /wp-admin/upload.php3.29 ▲0.0637.92 ▲1.60
Contractor Commerce /wp-admin/options-general.php?page=contractor_commerce3.2432.19

Server storage [IO: ▲0.06MB] [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: 23 new files
Database: no new tables, 6 new options
New WordPress options
widget_theysaidso_widget
theysaidso_admin_options
widget_recent-posts
db_upgraded
widget_recent-comments
can_compress_scripts

Browser metrics Passed 4 tests

Contractor Commerce Integration: an overview of browser usage
This plugin has a minimal impact on browser resources
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,906 ▲14513.64 ▼0.748.16 ▲6.1843.07 ▼1.09
Dashboard /wp-admin2,223 ▲175.82 ▲0.76106.03 ▲2.3035.13 ▼9.66
Posts /wp-admin/edit.php2,111 ▲111.99 ▼0.0040.81 ▲6.6534.87 ▲0.46
Add New Post /wp-admin/post-new.php1,533 ▲723.35 ▲5.81665.85 ▼45.0063.48 ▲8.39
Media Library /wp-admin/upload.php1,408 ▲84.23 ▼0.05109.81 ▲6.2746.33 ▲0.91
Contractor Commerce /wp-admin/options-general.php?page=contractor_commerce8802.0124.1526.00

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

Smoke tests 25% from 4 tests

Server-side errors 0% from 1 test

🔹 Test weight: 20 | A shallow check that no server-side errors were triggered
These errors were triggered by the plugin
  • 2 occurences, only the last one shown
    • > GET request to /wp-admin/options-general.php?page=contractor_commerce
    • > Notice in wp-content/plugins/contractor-commerce-integration/admin/partials/contractor-commerce-admin-settings.php+72
    Trying to access array offset on value of type bool

SRP 0% 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
  • 1× PHP files output non-empty strings when accessed directly via GET requests:
    • > /wp-content/plugins/contractor-commerce-integration/public/partials/contractor-commerce-public-display.php
  • 1× GET requests to PHP files trigger server-side errors or Error 500 responses:
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_action() in wp-content/plugins/contractor-commerce-integration/admin/partials/contractor-commerce-admin-settings.php:15

User-side errors Passed 1 test

🔹 Test weight: 20 | This is a shallow check for browser errors
No browser issues were found

Optimizations

Plugin configuration 93% from 29 tests

readme.txt Passed 16 tests

Perhaps the most important file in your plugin readme.txt gets parsed in order to generate the public listing of your plugin
3 plugin tags: hvac, contractor, ecommerce

contractor-commerce-integration/contractor-commerce.php 85% from 13 tests

The main PHP script in "Contractor Commerce Integration" version 1.0.2 is automatically included on every request by WordPress
Please take the time to fix the following:
  • Text Domain: The text domain must be the same as the plugin slug, although optional since WordPress version 4.6
  • Main file name: Name the main plugin file the same as the plugin slug ("contractor-commerce-integration.php" instead of "contractor-commerce.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
No dangerous file extensions were detected310 lines of code in 17 files:
LanguageFilesBlank linesComment linesLines of code
PHP12160535254
SVG10040
CSS20410
JavaScript24546

PHP code Passed 2 tests

Cyclomatic complexity and code structure are the fingerprint of this plugin
There are no cyclomatic complexity problems detected for this plugin
Cyclomatic complexity
Average complexity per logical line of code0.07
Average class complexity1.57
▷ Minimum class complexity1.00
▷ Maximum class complexity3.00
Average method complexity1.16
▷ 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

Using a strong compression for your PNG files is a great way to speed-up your plugin
PNG images were not found in this plugin