mirror of
https://gitlab.crans.org/nounous/ghostream.git
synced 2024-12-22 20:52:20 +00:00
Don't fail tests if the telnet module is not loaded
This commit is contained in:
parent
084ea676be
commit
029633d215
@ -122,7 +122,7 @@ func Serve(config *Options) {
|
|||||||
|
|
||||||
// GetNumberConnectedSessions returns the numbers of clients that are viewing the stream through a telnet shell
|
// GetNumberConnectedSessions returns the numbers of clients that are viewing the stream through a telnet shell
|
||||||
func GetNumberConnectedSessions(streamID string) int {
|
func GetNumberConnectedSessions(streamID string) int {
|
||||||
if !Cfg.Enabled {
|
if Cfg == nil || !Cfg.Enabled {
|
||||||
return 0
|
return 0
|
||||||
}
|
}
|
||||||
return clientCount[streamID]
|
return clientCount[streamID]
|
||||||
|
Loading…
Reference in New Issue
Block a user