Fixes flavor text from being removed when canceled.

This was because canceling really just sent a empty string and not null which caused it to set the flavor text to an empty string.
This commit is contained in:
Carlen White
2019-05-22 00:27:19 -04:00
parent e9c450bf17
commit bb2a8bdd59
3 changed files with 6 additions and 4 deletions
+1 -1
View File
@@ -1458,7 +1458,7 @@ GLOBAL_LIST_EMPTY(preferences_datums)
age = max(min( round(text2num(new_age)), AGE_MAX),AGE_MIN)
if("flavor_text")
var/msg = stripped_multiline_input(usr,"Set the flavor text in your 'examine' verb. This can also be used for OOC notes and preferences!","Flavor Text",html_decode(features["flavor_text"]), MAX_MESSAGE_LEN*2, TRUE) as null|message
var/msg = stripped_multiline_input(usr, "Set the flavor text in your 'examine' verb. This can also be used for OOC notes and preferences!", "Flavor Text", html_decode(features["flavor_text"]), MAX_MESSAGE_LEN*2, TRUE)
if(!isnull(msg))
msg = copytext(msg, 1, MAX_MESSAGE_LEN*2)
features["flavor_text"] = msg