I'm trying to send data from my first ViewController to my second One.
It works fine with a simple Int but with this Double it doesn't work and I don't understand why. So if you can explain why it doesn't work it's cool !
My declaration in first ViewController :
var time: Double? = 0.00
Then I try to send it to my other ViewController:
let vc = segue.destination as! MySecondViewController
vc.rows = rows[pathForAVC]
vc.lap = lap[pathForAVC]
vc.indexPath = pathForAVC
vc.time = rows[pathForAVC]["Time"]! as! Double
fatal error: unexpectedly found nil while unwrapping an Optional value
And my second ViewController:
var time: Double? = 0.00
topLabel.text = "\(time!)"
N.B:
rows is a Dictionnary:
var rows: [[String : AnyObject]] = [[:]]
I really don't understand my mistake...