Fix device_id and device_private for HomeKit config

This commit is contained in:
Alex X
2024-05-11 06:35:28 +03:00
parent 5ccbd7c1c2
commit 9160403b99
3 changed files with 7 additions and 8 deletions
+1 -1
View File
@@ -21,7 +21,7 @@ import (
func Init() { func Init() {
var conf struct { var conf struct {
API struct { API struct {
Listen string `json:"listen"` Listen string `yaml:"listen"`
} `yaml:"api"` } `yaml:"api"`
Mod struct { Mod struct {
Config string `yaml:"config"` Config string `yaml:"config"`
+5 -6
View File
@@ -22,12 +22,11 @@ import (
func Init() { func Init() {
var cfg struct { var cfg struct {
Mod map[string]struct { Mod map[string]struct {
Pin string `json:"pin"` Pin string `yaml:"pin"`
Name string `json:"name"` Name string `yaml:"name"`
DeviceID string `json:"device_id"` DeviceID string `yaml:"device_id"`
DevicePrivate string `json:"device_private"` DevicePrivate string `yaml:"device_private"`
Pairings []string `json:"pairings"` Pairings []string `yaml:"pairings"`
//Listen string `json:"listen"`
} `yaml:"homekit"` } `yaml:"homekit"`
} }
app.LoadConfig(&cfg) app.LoadConfig(&cfg)
+1 -1
View File
@@ -21,7 +21,7 @@ func Init() {
Username string `yaml:"username" json:"-"` Username string `yaml:"username" json:"-"`
Password string `yaml:"password" json:"-"` Password string `yaml:"password" json:"-"`
DefaultQuery string `yaml:"default_query" json:"default_query"` DefaultQuery string `yaml:"default_query" json:"default_query"`
PacketSize uint16 `yaml:"pkt_size"` PacketSize uint16 `yaml:"pkt_size" json:"packet_size"`
} `yaml:"rtsp"` } `yaml:"rtsp"`
} }