homebridge-securitysystem 6.3.0-beta.2 → 6.3.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -333,13 +333,6 @@
333
333
  "de-DE"
334
334
  ]
335
335
  },
336
- "audio_configuration": {
337
- "title": "Audio Configuration",
338
- "type": "string",
339
- "required": false,
340
- "default": "SDL_AUDIODRIVER=\"alsa\" AUDIODEV=\"hw:0,0\"",
341
- "placeholder": "SDL_AUDIODRIVER=\"alsa\" AUDIODEV=\"hw:0,0\""
342
- },
343
336
  "audio_path": {
344
337
  "title": "Custom Audio Path",
345
338
  "description": "Instructions will be created in this path.",
@@ -660,7 +653,6 @@
660
653
  "audio_language"
661
654
  ]
662
655
  },
663
- "audio_configuration",
664
656
  {
665
657
  "type": "div",
666
658
  "displayFlex": true,
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "homebridge-securitysystem",
3
3
  "displayName": "Homebridge Security System",
4
- "version": "6.3.0-beta.2",
4
+ "version": "6.3.1",
5
5
  "description": "Homebridge plugin that creates a security system accessory that can be triggered by HomeKit sensors.",
6
6
  "main": "src/index.js",
7
7
  "scripts": {
package/src/index.js CHANGED
@@ -1304,19 +1304,11 @@ SecuritySystem.prototype.playAudio = async function (type, state) {
1304
1304
  }
1305
1305
 
1306
1306
  // Process
1307
- let command = '';
1308
-
1309
- if (options.isValueSet(options.audioConfiguration)) {
1310
- command += `${options.audioConfiguration} `;
1311
- }
1312
-
1313
- command += `ffplay ${commandArguments.join(' ')}`;
1314
-
1315
- this.audioProcess = spawn(command, { shell: true });
1316
- this.log.debug(command);
1307
+ this.audioProcess = spawn('ffplay', commandArguments);
1308
+ this.log.debug(`ffplay ${commandArguments.join(' ')}`);
1317
1309
 
1318
1310
  this.audioProcess.on('error', data => {
1319
- // Check if ffmpeg is installed
1311
+ // Check if command is missing
1320
1312
  if (data !== null && data.toString().indexOf('ENOENT') > -1) {
1321
1313
  this.log.error('Unable to play sound, ffmpeg is not installed.');
1322
1314
  return;
@@ -70,7 +70,6 @@ const options = {
70
70
 
71
71
  // Audio
72
72
  options.audio = config.audio;
73
- options.audioConfiguration = config.audio_configuration;
74
73
  options.audioPath = config.audio_path;
75
74
  options.audioLanguage = config.audio_language;
76
75
  options.audioVolume = config.audio_volume;