UNPKG

homebridge-switchbot-bluetooth-platform

Version:

A Homebridge platform Plugin for controlling SwitchBot bots using BLE (Bluetooth Low Energry)

14 lines 734 B
"use strict"; Object.defineProperty(exports, "__esModule", { value: true }); exports.logSwitchbotClientError = void 0; const logSwitchbotClientError = (logger, error) => { var _a; const errorMessage = `${error}`; const isInitializationError = (_a = errorMessage === null || errorMessage === void 0 ? void 0 : errorMessage.toLowerCase()) === null || _a === void 0 ? void 0 : _a.includes('failed to initialize'); if (isInitializationError) { logger.error('Failed initializing switchbot client. Please make sure that the bluetooth is accessible on your homebridge server'); } logger.error(errorMessage); }; exports.logSwitchbotClientError = logSwitchbotClientError; //# sourceMappingURL=errorLogger.js.map