Converted all strftime to a try statement to prevent errors in view.