Started reworking skaldctl. Give room status along with room name.
This commit is contained in:
@@ -405,6 +405,11 @@ func validHallName(name string) bool {
|
||||
return s == "/"+name
|
||||
}
|
||||
|
||||
// ValidHallName reports whether name is safe to use as a hall name.
|
||||
func ValidHallName(name string) bool {
|
||||
return validHallName(name)
|
||||
}
|
||||
|
||||
func add(name string, desc *Description) (*Hall, []Client, error) {
|
||||
if !validHallName(name) {
|
||||
return nil, nil, UserError("illegal hall name")
|
||||
@@ -1034,6 +1039,11 @@ func validUsername(username string) bool {
|
||||
return username != "" && validHallName(username)
|
||||
}
|
||||
|
||||
// ValidUsername reports whether username is safe to use as a login name.
|
||||
func ValidUsername(username string) bool {
|
||||
return validUsername(username)
|
||||
}
|
||||
|
||||
// called locked
|
||||
func (g *Hall) getPermission(creds ClientCredentials) (string, []string, error) {
|
||||
desc := g.description
|
||||
@@ -1097,6 +1107,7 @@ type Status struct {
|
||||
AuthServer string `json:"authServer,omitempty"`
|
||||
AuthPortal string `json:"authPortal,omitempty"`
|
||||
Locked bool `json:"locked,omitempty"`
|
||||
Recording bool `json:"recording,omitempty"`
|
||||
ClientCount *int `json:"clientCount,omitempty"`
|
||||
CanChangePassword bool `json:"canChangePassword,omitempty"`
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user