mirror of
https://github.com/MetaCubeX/mihomo.git
synced 2026-12-01 15:56:50 +00:00
fix: validation error handling for age-secret-key
This commit is contained in:
1 parent
f99d4e1be6
commit
1abd12619a
1 file changed
+4
-2
@@ -366,8 +366,10 @@ func NewProxiesParser(pdName string, tunnel C.Tunnel, filter string, excludeFilt
|
||||
filterRegs = append(filterRegs, filterReg)
|
||||
}
|
||||
|
||||
if err := age.VeritySecretKeys(ageSecretKey); err != nil {
|
||||
return nil, fmt.Errorf("invalid age-secret-key: %w", err)
|
||||
if ageSecretKey != "" {
|
||||
if err := age.VeritySecretKeys(ageSecretKey); err != nil {
|
||||
return nil, fmt.Errorf("invalid age-secret-key: %w", err)
|
||||
}
|
||||
}
|
||||
|
||||
return func(buf []byte) ([]C.Proxy, error) {
|
||||
|
||||
Reference in new issue
Block a user