added logic for generating random key & the recover email for user