Remove code duplicating newer RES functionality