pub fn string_to_epoch(date: &str) -> Result<i64, Box<dyn Error>>
Function to change string to epoch format.