Fix crash on 1.7.7