updated commands so they can work for multiple ranks