Skip to content

Commit

Permalink
update docs / messages
Browse files Browse the repository at this point in the history
  • Loading branch information
regaw-leinad committed Aug 19, 2024
1 parent fdb9f6d commit bd1c8a8
Show file tree
Hide file tree
Showing 2 changed files with 13 additions and 7 deletions.
12 changes: 6 additions & 6 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -36,7 +36,7 @@
- **Reliability**: Automatically refreshes device list on a configurable interval to ensure devices are always
up-to-date.
- **Seamless Authentication**: Automatically refreshes your Winix authentication token in the background, so you no
longer need to manually re-login every 30 days.
longer need to manually re-authorize every 30 days.
- **Encrypted Storage**: Your Winix account password and refresh token are securely stored on disk using encryption,
keeping your credentials safe.

Expand Down Expand Up @@ -67,9 +67,9 @@ Wiki page.
### Important: Set Your Encryption Key

For added security, you should set the `WINIX_ENCRYPTION_KEY` environment variable when running Homebridge. This will
allow you to use your own custom encryption key to protect your stored password and refresh token. If this variable is
not set, the plugin will use a static default key, which is less secure. Directions for setting custom environment
variables can be found in the [Homebridge documentation](https://github.com/homebridge/homebridge/wiki).
allow you to use your own custom encryption key string to protect your stored password and refresh token. If this
variable is not set, the plugin will use a static default key, which is less secure. Directions for setting custom
environment variables can be found in the [Homebridge documentation](https://github.com/homebridge/homebridge/wiki).

### Homebridge Configuration UI

Expand Down Expand Up @@ -174,8 +174,8 @@ use.

3. **Update your configuration**:

The script will output the encrypted password. Copy the result and paste it into the `"password"` field in your
`config.json` under the `"auth"` section:
The script will output your encrypted password. Copy the result and paste it into the `password` field in your
`config.json` under the `auth` section:

```json
{
Expand Down
8 changes: 7 additions & 1 deletion src/platform.ts
Original file line number Diff line number Diff line change
Expand Up @@ -187,13 +187,19 @@ export class WinixPurifierPlatform implements DynamicPlatformPlugin {
}

private notConfigured(): void {
this.log.error('');
this.log.error('');

this.log.error('Winix Purifiers is NOT set up. ' +
'Please link your Winix account in the Homebridge UI.');

// Message for users migrating from a previous version of the
// plugin which required a refresh token in the config
if (this.config.auth && this.config.auth['refreshToken']) {
this.log.error('This version of the plugin requires re-linking your Winix account.');
this.log.error('The new version of this plugin (v2.1.0+) requires re-linking your Winix account.');
}

this.log.error('');
this.log.error('');
}
}

0 comments on commit bd1c8a8

Please sign in to comment.