Replace deprecated Date.parse with SimpleDateFormat.parse