Remove duplicate encrypt() functions