implement NS RENAME

Fixes #1380
This commit is contained in:
Shivaram Lingamneni 2020-11-10 19:59:12 -05:00
parent 4861ac90b6
commit 4f571c2cf3
4 changed files with 69 additions and 0 deletions

View file

@ -300,6 +300,13 @@ func (client *Client) Login(account ClientAccount) {
return
}
func (client *Client) setAccountName(name string) {
// XXX this assumes validation elsewhere
client.stateMutex.Lock()
defer client.stateMutex.Unlock()
client.accountName = name
}
func (client *Client) historyCutoff() (cutoff time.Time) {
client.stateMutex.Lock()
if client.account != "" {