[mr3246] Fix possible crash in Achievements code. Thanks to ike3 for pointing. Close #1443