Added check to prevent infinnite recursion from misbehaving servers