fixes crash issue