forked from git.klmp200.net/ALFRED
Fix empty gender
This commit is contained in:
parent
747e58099e
commit
68f6e1ffa0
@ -2,7 +2,7 @@
|
||||
* @Author: Bartuccio Antoine
|
||||
* @Date: 2018-07-24 14:55:33
|
||||
* @Last Modified by: klmp200
|
||||
* @Last Modified time: 2018-07-25 01:05:08
|
||||
* @Last Modified time: 2018-07-25 01:29:53
|
||||
*/
|
||||
|
||||
package commands
|
||||
@ -24,6 +24,10 @@ func SetGender(m *tb.Message) {
|
||||
return
|
||||
}
|
||||
data := strings.Join(split, " ")
|
||||
if data == "" {
|
||||
shared.Bot.Send(m.Chat, "Attention, votre genre est vide. Ce n'est pas enregistrable.")
|
||||
return
|
||||
}
|
||||
shared.Users.Set(m.Sender.Username, "gender", data)
|
||||
shared.Bot.Send(m.Chat, "Votre genre est enregistré, je vous considère maintenant comme « "+data+" ».")
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user