Update accountlink.dm

should've done this way before
This commit is contained in:
BongaTheProto
2022-03-21 14:33:35 -05:00
parent 85f477baf6
commit 309faab563
@@ -26,10 +26,15 @@
else
var/existing_id = SSdiscord.lookup_id(usr?.ckey)
//Do not create a new entry if they already have a linked account
if(existing_id)
message = "You already have a linked account with discord ID ([existing_id]). If you desire to change your account please contact staff."
// Will generate one if an expired one doesn't exist already, otherwise will grab existing token
var/one_time_token = SSdiscord.get_or_generate_one_time_token_for_ckey(ckey)
SSdiscord.reverify_cache[usr.ckey] = one_time_token
message = "Your one time token is: \"[one_time_token]\". You can now verify yourself in discord by using the command <span class='warning'>\"[prefix][command] [one_time_token]\"</span>"
else
var/one_time_token = SSdiscord.get_or_generate_one_time_token_for_ckey(ckey)
SSdiscord.reverify_cache[usr.ckey] = one_time_token
message = "Your one time token is: \"[one_time_token]\". You can now verify yourself in discord by using the command <span class='warning'>\"[prefix][command] [one_time_token]\"</span>"
//Now give them a browse window so they can't miss whatever we told them
var/datum/browser/window = new/datum/browser(usr, "discordverification", "Discord verification")