diff --git a/index.html b/index.html
index 5ef1c3a..c5078b4 100644
--- a/index.html
+++ b/index.html
@@ -409,8 +409,8 @@
be setting the overrides
property on
<esp-web-install-button>
. The value is an object
containing a
- checkSameFirmwareVersion(manifest, improvInfo)
function.
- The manifest
parameter is your manifest and
+ checkSameFirmware(manifest, improvInfo)
function. The
+ manifest
parameter is your manifest and
improvInfo
is the information returned from Improv:
{ name, firmware, version, chipFamily }
. This check is only
called if the device firmware was detected via Improv.
@@ -418,7 +418,7 @@
const button = document.querySelector('esp-web-install-button'); button.overrides = { - checkSameFirmwareVersion(manifest, improvInfo) { + checkSameFirmware(manifest, improvInfo) { const manifestFirmware = manifest.name.toLowerCase(); const deviceFirmware = improvInfo.firmware.toLowerCase(); return manifestFirmware.includes(deviceFirmware); diff --git a/src/install-dialog.ts b/src/install-dialog.ts index 70b84a8..ec2c0bb 100644 --- a/src/install-dialog.ts +++ b/src/install-dialog.ts @@ -38,7 +38,7 @@ export class EwtInstallDialog extends LitElement { public logger: Logger = console; public overrides?: { - checkSameFirmwareVersion?: ( + checkSameFirmware?: ( manifest: Manifest, deviceImprov: ImprovSerial["info"] ) => boolean; @@ -886,8 +886,8 @@ export class EwtInstallDialog extends LitElement { private get _isSameFirmware() { return !this._info ? false - : this.overrides?.checkSameFirmwareVersion - ? this.overrides.checkSameFirmwareVersion(this._manifest, this._info) + : this.overrides?.checkSameFirmware + ? this.overrides.checkSameFirmware(this._manifest, this._info) : this._info.firmware === this._manifest.name; }