|
|
|
@ -259,6 +259,10 @@ func (c *Client) ProcessTransportCommand(cmdline string, resource string) string
|
|
|
|
|
return telegramNotInitialized
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
if c.authorizer.isClosed {
|
|
|
|
|
return "Authorization is done already"
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
switch cmd {
|
|
|
|
|
// sign in
|
|
|
|
|
case "login":
|
|
|
|
@ -290,7 +294,7 @@ func (c *Client) ProcessTransportCommand(cmdline string, resource string) string
|
|
|
|
|
// cancel auth
|
|
|
|
|
case "cancelauth":
|
|
|
|
|
if c.Online() {
|
|
|
|
|
return "Not allowed when online"
|
|
|
|
|
return "Not allowed when online, use /logout instead"
|
|
|
|
|
}
|
|
|
|
|
c.cancelAuth()
|
|
|
|
|
return "Cancelled"
|
|
|
|
|