title: Error : "Thread 1: EXC_BAD_ACCESS (code=2, address=0x7ffee0234ff0)"
body: <p>I have this code and when I am running the App on the line with <code>&quot;super.viewDidLoad()&quot;</code>, I have the &quot;Thread 1: EXC_BAD_ACCESS (code=2, address=0x7ffee0234ff0&quot; error...
  Can someone help me please?</p>
  <p>On internet they say me that I have to connect my Developer Account, but I don't have one.</p>
  <h2>This is the code :</h2>
  <pre><code>import Foundation
  import UIKit
  import FirebaseAuth
  import FirebaseDatabase
  
  
  
  class SignUpController : UIViewController {
  
  
  
  //Fonction pour scroller
  private let scrollView: UIScrollView = {
      let scrollView = UIScrollView.self()
      scrollView.clipsToBounds = true
      return scrollView
      
  }()
  
  //MARK : Outlets
  @IBOutlet weak var artistnameTextField: UITextField!
  @IBOutlet weak var emailTextField: UITextField!
  @IBOutlet weak var passwordTextField: UITextField!
  @IBOutlet weak var confirmationPasswordTextField: UITextField!
  
  @IBOutlet weak var signupButton: UIButton!
  @IBOutlet weak var loginButton: UIButton!
  
  //MARK : Properties
  
  
  override func viewDidLoad() {
      super.viewDidLoad()
      viewDidLoad()
      
      
  //Add subviews
      view.addSubview(scrollView)
      scrollView.addSubview(artistnameTextField)
      scrollView.addSubview(emailTextField)
      scrollView.addSubview(passwordTextField)
      scrollView.addSubview(confirmationPasswordTextField)
      scrollView.addSubview(signupButton)
      scrollView.addSubview(loginButton)
      
      //Design
      setupButtons()
      
      
  }
  
  override func prepare(for segue: UIStoryboardSegue, sender: Any?) {
      if segue.identifier == &quot;showLogin&quot; {
          let VCDestination = segue.destination as! LoginController
          VCDestination.myMail = emailTextField.text!
      }
      if segue.identifier == &quot;showLogin&quot; {
          let VCDestination = segue.destination as! LoginController
          VCDestination.myPassword = passwordTextField.text!
      }
  }
  
  
  
  
  //MARK : Private Methods
  private func setupButtons() {
      signupButton.layer.cornerRadius = 20
      
      loginButton.layer.cornerRadius = 20
      loginButton.layer.borderWidth = 3
      loginButton.layer.borderColor = UIColor.lightGray.cgColor
  }
  
  private func setupTextFieldManager() {
      artistnameTextField.delegate = self
      emailTextField.delegate = self
      passwordTextField.delegate = self
      
      let tapGesture = UITapGestureRecognizer (target: self, action: #selector(hideKeyboard))
      view.addGestureRecognizer(tapGesture)
  }
  
  //MARK : Actions
  @IBAction func signUpButton(_ sender: UIButton) {
      performSegue(withIdentifier: &quot;showLogin&quot;, sender: nil)
  }
  
  
  
  @objc private func hideKeyboard() {
      artistnameTextField.resignFirstResponder()
      emailTextField.resignFirstResponder()
      passwordTextField.resignFirstResponder()
  }
  
  
  
  @IBAction func signupButtonWasPressed(_ sender: UIButton) {
      if artistnameTextField !== &quot;&quot; as AnyObject &amp;&amp; emailTextField !== &quot;&quot; as AnyObject &amp;&amp; passwordTextField !== &quot;&quot; as AnyObject &amp;&amp; confirmationPasswordTextField.text == passwordTextField.text {
          
          
          Auth.auth().createUser(withEmail: emailTextField.text!, password: passwordTextField.text!) { (authResult, error) in
              if error != nil {
                  print(error.debugDescription)
                  self.alertUserLoginError()
              } else {
                  print (&quot;Inscription en cours...&quot;)
                  
                  let ref = Database.database().reference()
                  let userID = Auth.auth().currentUser?.uid
                  
                  ref.child(&quot;users&quot;).child(userID!).setValue([&quot;artistName&quot;: self.artistnameTextField.text])
                  
                  self.performSegue(withIdentifier: &quot;goToHome&quot;, sender:  self)
              }
          }
          
      } else {
          print(&quot;Veuillez remplir tous les champs.&quot;)
      }
  }
  @IBAction func loginButtonWasPressed(_ sender: UIButton) {
      print(&quot;Redirection vers l'écran de connexion...&quot;)
  }
  
  func alertUserLoginError() {
      let alert = UIAlertController(title: &quot;Erreur&quot;, message: &quot;Veuillez remplir tous les champs&quot;, preferredStyle: .alert)
      
      alert.addAction(UIAlertAction(title: &quot;Dismiss&quot;, style: .cancel, handler: nil))
      present(alert, animated: true)
  }
  
  
  }
  
  extension SignUpController: UITextFieldDelegate{
      func textFieldShouldReturn(_ textField: UITextField) -&gt; Bool {
      textField.resignFirstResponder()
      
      return true
  }
  
  
  }
  </code></pre>
  <p>Thanks</p>