Fix old photos (#61835)

Fixes old photos in the old braindead saving system not saving. I have a backup of some photo saves starting now, but can't promise anything, and if you lost them, they're probably just gone.

Finding this bug would've required some insanely frustrating testing, so I'm not too bent up about it.
This commit is contained in:
Mothblocks
2021-10-04 15:56:19 +01:00
committed by GitHub
parent 5a60e6bc67
commit 7af96e9ca5
+7 -1
View File
@@ -105,7 +105,13 @@
if(!json[id])
return
var/datum/picture/P = new
P.deserialize_list(json[id])
// Old photos were saved as, and I shit you not, encoded JSON strings.
if (istext(json[id]))
P.deserialize_json(json[id])
else
P.deserialize_list(json[id])
return P
/proc/log_path_from_picture_ID(id)