Replace 'formatString' with 'formattedDate'