    
     // This is one of the reasons why it's a good idea for disposal to be detached from allocations.
     // If resources weren't disposed before view controller is being deallocated, signup alert view
-    // could be presented on top of wrong screen or crash your app if it was being presented while
-    // navigation stack is popping.
+    // could be presented on top of the wrong screen or could crash your app if it was being presented 
+    // while navigation stack is popping.
+    
     // This will work well with UINavigationController, but has an assumption that view controller will
     // never be readded as a child view controller.
-    // It it was readded UI wouldn't be bound anymore.
+    // If it was readded the UI wouldn't be bound anymore.
     override func willMoveToParentViewController(parent: UIViewController?) {
         if let parent = parent {
             assert(parent.isKindOfClass(UINavigationController), "Please read comments")

import RxCocoa
#endif

let okColor = UIColor(red: 138.0 / 255.0, green: 221.0 / 255.0, blue: 109.0 / 255.0, alpha: 1.0)
let errorColor = UIColor.redColor()

typealias ValidationResult = (valid: Bool?, message: String?)
typealias ValidationObservable = Observable<ValidationResult>


        super.viewDidLoad()
        
        let tapBackground = UITapGestureRecognizer(target: self, action: Selector("dismissKeyboard:"))
        view.addGestureRecognizer(tapBackground)
        
        self.disposeBag = DisposeBag()
