From 83f13322299c19d55eee0db4fd603c2f879f78f1 Mon Sep 17 00:00:00 2001 From: kevinz000 <2003111+kevinz000@users.noreply.github.com> Date: Sun, 8 Apr 2018 19:39:06 -0700 Subject: [PATCH 1/3] >wiped my flavortext accidently --- modular_citadel/code/modules/client/preferences.dm | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/modular_citadel/code/modules/client/preferences.dm b/modular_citadel/code/modules/client/preferences.dm index c2dee71a4f..d1fe2d3d73 100644 --- a/modular_citadel/code/modules/client/preferences.dm +++ b/modular_citadel/code/modules/client/preferences.dm @@ -253,7 +253,7 @@ if("input") switch(href_list["preference"]) 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 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) as null|message if(msg != null) msg = copytext(msg, 1, MAX_MESSAGE_LEN*2) features["flavor_text"] = msg From cd38bccf01c586c8d997d1007803cf96cf51e7a1 Mon Sep 17 00:00:00 2001 From: kevinz000 <2003111+kevinz000@users.noreply.github.com> Date: Sun, 8 Apr 2018 19:40:28 -0700 Subject: [PATCH 2/3] why --- code/__HELPERS/_cit_helpers.dm | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/code/__HELPERS/_cit_helpers.dm b/code/__HELPERS/_cit_helpers.dm index 83211d7ee6..9e38d9cf1e 100644 --- a/code/__HELPERS/_cit_helpers.dm +++ b/code/__HELPERS/_cit_helpers.dm @@ -108,8 +108,8 @@ GLOBAL_VAR_INIT(miscreants_allowed, FALSE) set desc = "Sets an extended description of your character's features." set category = "IC" - var/new_flavor = (input(src, "Enter your new flavor text:", "Flavor text", null) as text|null) - if(new_flavor) + var/new_flavor = input(src, "Enter your new flavor text:", "Flavor text", null) as message|null + if(!isnull(new_flavor)) flavor_text = sanitize(new_flavor) to_chat(src, "Your flavor text has been updated.") From 820f4e7998465a4c6cb1c10ae4b69ea82b18e564 Mon Sep 17 00:00:00 2001 From: kevinz000 <2003111+kevinz000@users.noreply.github.com> Date: Sun, 8 Apr 2018 19:40:57 -0700 Subject: [PATCH 3/3] Update preferences.dm --- modular_citadel/code/modules/client/preferences.dm | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/modular_citadel/code/modules/client/preferences.dm b/modular_citadel/code/modules/client/preferences.dm index d1fe2d3d73..741e6f0935 100644 --- a/modular_citadel/code/modules/client/preferences.dm +++ b/modular_citadel/code/modules/client/preferences.dm @@ -254,7 +254,7 @@ switch(href_list["preference"]) 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 - if(msg != null) + if(!isnull(msg)) msg = copytext(msg, 1, MAX_MESSAGE_LEN*2) features["flavor_text"] = msg