forked from git.klmp200.net/ALFRED
Removed @ from genders
This commit is contained in:
parent
54517b8e99
commit
747e58099e
@ -2,7 +2,7 @@
|
|||||||
* @Author: Bartuccio Antoine
|
* @Author: Bartuccio Antoine
|
||||||
* @Date: 2018-07-24 14:55:33
|
* @Date: 2018-07-24 14:55:33
|
||||||
* @Last Modified by: klmp200
|
* @Last Modified by: klmp200
|
||||||
* @Last Modified time: 2018-07-25 00:19:03
|
* @Last Modified time: 2018-07-25 01:05:08
|
||||||
*/
|
*/
|
||||||
|
|
||||||
package commands
|
package commands
|
||||||
@ -53,13 +53,11 @@ func Gender(m *tb.Message) {
|
|||||||
func cleanGender(slice []string) []string {
|
func cleanGender(slice []string) []string {
|
||||||
for i := range slice {
|
for i := range slice {
|
||||||
slice[i] = strings.Replace(slice[i], "\\", "", -1)
|
slice[i] = strings.Replace(slice[i], "\\", "", -1)
|
||||||
|
slice[i] = strings.Replace(slice[i], "@", "", -1)
|
||||||
clean := false
|
clean := false
|
||||||
for !clean {
|
for !clean {
|
||||||
clean = true
|
clean = true
|
||||||
if strings.HasPrefix(slice[i], "@") {
|
if strings.HasPrefix(slice[i], "/") {
|
||||||
slice[i] = strings.Replace(slice[i], "@", "", 1)
|
|
||||||
clean = false
|
|
||||||
} else if strings.HasPrefix(slice[i], "/") {
|
|
||||||
slice[i] = strings.Replace(slice[i], "/", "", 1)
|
slice[i] = strings.Replace(slice[i], "/", "", 1)
|
||||||
clean = false
|
clean = false
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user