Browse Source

confwatcher: remove redundant code (#2592)

pull/2594/head
Alessandro Ros 2 years ago committed by GitHub
parent
commit
f11f39f023
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
  1. 9
      internal/confwatcher/confwatcher.go

9
internal/confwatcher/confwatcher.go

@ -30,14 +30,7 @@ type ConfWatcher struct { @@ -30,14 +30,7 @@ type ConfWatcher struct {
// New allocates a ConfWatcher.
func New(confPath string) (*ConfWatcher, error) {
if _, err := os.Stat(confPath); err != nil {
if confPath == "mediamtx.yml" {
confPath = "rtsp-simple-server.yml"
if _, err := os.Stat(confPath); err != nil {
return nil, err
}
} else {
return nil, err
}
return nil, err
}
inner, err := fsnotify.NewWatcher()

Loading…
Cancel
Save