fixed ordering of adapted rand error return values