<commit_before>//
//  AutoNextViewController.swift
//
//  Created by <NAME> on 5/04/2016.
//  Copyright © 2016 BareFeetWare.
//  Free to use at your own risk, with acknowledgement to BareFeetWare.
//

import UIKit

class AutoNextViewController: UIViewController {

    // MARK: - Variables
    
    @IBInspectable var segueIdentifier: String = "next"
    @IBInspectable var delay: Double = 0.5
    @IBInspectable var duration: Double = 1.0
    
    // MARK: - UIViewController

    override func viewDidAppear(animated: Bool) {
        super.viewDidAppear(animated)
        let dispatchTime = dispatch_time(DISPATCH_TIME_NOW, Int64(delay))
        dispatch_after(dispatchTime, dispatch_get_main_queue()) {
            self.performSegueWithIdentifier(self.segueIdentifier, sender: self)
        }
    }
    
    override func prepareForSegue(segue: UIStoryboardSegue, sender: AnyObject?) {
        if let morphSegue = segue as? MorphSegue {
            morphSegue.duration = duration
        }
    }

}
<commit_msg>AutoNextViewController: Fixed delay to be seconds (was nanoseconds)<commit_after>//
//  AutoNextViewController.swift
//
//  Created by <NAME> on 5/04/2016.
//  Copyright © 2016 BareFeetWare.
//  Free to use at your own risk, with acknowledgement to BareFeetWare.
//

import UIKit

class AutoNextViewController: UIViewController {

    // MARK: - Variables
    
    @IBInspectable var segueIdentifier: String = "next"
    @IBInspectable var delay: Double = 0.5
    @IBInspectable var duration: Double = 1.0
    
    // MARK: - UIViewController

    override func viewDidAppear(animated: Bool) {
        super.viewDidAppear(animated)
        let dispatchTime = dispatch_time(DISPATCH_TIME_NOW, Int64(delay * Double(NSEC_PER_SEC)))
        dispatch_after(dispatchTime, dispatch_get_main_queue()) {
            self.performSegueWithIdentifier(self.segueIdentifier, sender: self)
        }
    }
    
    override func prepareForSegue(segue: UIStoryboardSegue, sender: AnyObject?) {
        if let morphSegue = segue as? MorphSegue {
            morphSegue.duration = duration
        }
    }

}

{'fraction_non_alphanumeric': 0.09026128266033254, 'fraction_numerical': 0.016152019002375298, 'mean_word_length': 2.9144981412639406, 'pattern_counts': {'":': 0, '<': 5, '<?xml version=': 0, '>': 5, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '4671139', 'n_tokens_mistral': 695, 'n_tokens_neox': 638, 'n_words': 156}