!pm users changes

This commit is contained in:
Aine
2022-08-30 15:00:34 +03:00
parent 00b84fba0e
commit ea1ef9da7f
2 changed files with 7 additions and 3 deletions

View File

@@ -28,7 +28,11 @@ func (s botSettings) Set(key, value string) {
// Users option
func (s botSettings) Users() []string {
return strings.Split(s.Get(botOptionUsers), " ")
value := s.Get(botOptionUsers)
if strings.Contains(value, " ") {
return strings.Split(value, " ")
}
return []string{}
}
// TODO: remove after migration