Fixes some runtimes (#3727)

This commit is contained in:
Ron
2017-10-22 02:37:44 +03:00
committed by Erki
parent 42e843d20d
commit 0d0117dcff
13 changed files with 41 additions and 17 deletions
+8 -1
View File
@@ -235,7 +235,14 @@
update_connection_data(C)
return
var/list/data_object = json_decode(data)
var/list/data_object
try
data_object = json_decode(data)
catch(var/exception/E)
data_object = list()
log_debug("CONN DATA: [E] encountered when loading data for [C.ckey].")
if (!data_object || !data_object.len)
log_debug("CONN DATA: [C.ckey] has no connection data to showcase.")
+1 -1
View File
@@ -1046,7 +1046,7 @@ var/list/admin_verbs_cciaa = list(
var/mob/living/silicon/ai/target = input("Choose the AI to force-wipe:", "AI Termination") as null|anything in ai_list
if (alert("Are you sure you want to wipe [target.name]? They will be ghosted and their job slot freed.", "Confirm AI Termination", "No", "No", "Yes") != "Yes")
if (!target || alert("Are you sure you want to wipe [target.name]? They will be ghosted and their job slot freed.", "Confirm AI Termination", "No", "No", "Yes") != "Yes")
return
log_and_message_admins("admin-wiped [key_name_admin(target)]'s core.")