small crash fix with orientation