fix ally check