Fixed crash on resume
0.5.24