Updated for changes to NSDate in Swift.