Reflect the changes in main.go.
This commit is contained in:
parent
e8e3570a8f
commit
a7d91dc92e
@ -4,7 +4,6 @@ import (
|
||||
"dwelling-radio/internal/configuration"
|
||||
"dwelling-radio/internal/handlers"
|
||||
"dwelling-radio/internal/radio"
|
||||
"dwelling-radio/internal/radio/liquidsoap"
|
||||
"dwelling-radio/pkg/logging"
|
||||
"dwelling-radio/pkg/server"
|
||||
"errors"
|
||||
@ -67,15 +66,15 @@ func main() {
|
||||
srv.GET("/playlist", hand.Playlist)
|
||||
|
||||
if !*noLiquidsoap {
|
||||
liquid, err := liquidsoap.NewLiquidsoap(config.Liquidsoap.ExecPath, config.Liquidsoap.ScriptPath)
|
||||
liquid, err := radio.NewLiquidsoap(config.Liquidsoap.ExecPath, config.Liquidsoap.ScriptPath)
|
||||
if err != nil {
|
||||
logErr.Fatalln("liquidsoap:", err)
|
||||
}
|
||||
|
||||
defer func() {
|
||||
if err := liquid.Stop(); err != nil {
|
||||
if !errors.Is(err, liquidsoap.ErrNotRunning) {
|
||||
logErr.Println("liquidsoap:", err)
|
||||
if !errors.Is(err, radio.ErrLiquidsoapNotRunning) {
|
||||
logErr.Println(err)
|
||||
}
|
||||
}
|
||||
}()
|
||||
|
Loading…
Reference in New Issue
Block a user