I have a function to convert string to date format. This function works as expected on iOS 12 but on iOS 13. I get this error:

> 
> "Thread 1: Fatal error: Unexpectedly found nil while unwrapping an Optional value"
> 
> 
> 

Here is my code:

```swift
func ConvertDateAndTimeFormat2() {
     let timeDate = "2019-09-24 15:00:00 +0000"
     let dateFormatter = DateFormatter()
     dateFormatter.dateFormat = "yyyy-MM-dd HH:mm:ss +zzzz"
     dateFormatter.timeZone = TimeZone(abbreviation: "GMT+3:00")
     var dateObj:Date!
     dateObj = dateFormatter.date(from: timeDate)
     dateFormatter.dateFormat = "EEEE, MMM d, yyyy"
     dateFormatter.timeZone = TimeZone(abbreviation: "GMT+3:00")

     let timeFormatter = DateFormatter()

     timeFormatter.dateFormat = "yyyy-MM-dd HH:mm:ss +zzzz"
     timeFormatter.timeZone = TimeZone(abbreviation: "GMT+3:00")
     var timeObj:Date!
     timeObj = timeFormatter.date(from: timeDate)

     timeFormatter.dateFormat = "HH:mm"
     timeFormatter.timeZone = TimeZone(abbreviation: "GMT+3:00")
     let timef = "\(timeFormatter.string(from: timeObj!))"
     let Date = "\(dateFormatter.string(from: dateObj!))"
 }

```