<commit_before>import UIKit

protocol Flow {
    func present(_ viewController: UIViewController)
    func dismiss()
}

extension UIWindow: Flow {
    func present(_ viewController: UIViewController) {
        self.rootViewController = viewController
        self.makeKeyAndVisible()
    }

    func dismiss() {
        self.rootViewController = nil
    }
}<commit_msg>Adding into to the flow<commit_after>import UIKit

protocol Flow {
    func present(_ viewController: UIViewController, animated: Bool)
    func dismiss(_ animated: Bool)
}

extension UIWindow: Flow {
    func present(_ viewController: UIViewController, animated: Bool) {
        self.rootViewController = viewController
        self.makeKeyAndVisible()
    }

    func dismiss(animated: Bool) {
        self.rootViewController = nil
    }
}

extension UINavigationController: Flow {
    func present(_ viewController: UIViewController, animated: Bool) {
        self.pushViewController(viewController, animated: animated)
    }

    func dismiss(_ animated: Bool) {
        self.popViewController(animated: animated)
    }
}

extension UIViewController: Flow {
    func present(_ viewController: UIViewController, animated: Bool) {
        self.present(viewController, animated: animated, completion: nil)
    }

    func dismiss(_ animated: Bool) {
        self.dismiss(animated: animated, completion: nil)
    }
}

extension UIViewController {
    var modalFlow: Flow {
        return self
    }

    var navigationFlow: Flow? {
        return self.navigationController
    }
}
{'fraction_non_alphanumeric': 0.08134280180761781, 'fraction_numerical': 0.0, 'mean_word_length': 3.2699724517906334, 'pattern_counts': {'":': 0, '<': 3, '<?xml version=': 0, '>': 3, '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': '3944996', 'n_tokens_mistral': 426, 'n_tokens_neox': 395, 'n_words': 111}