fix for a loop in allowed?