title: equals method doesn't work
body: <p>I'm practicing a simple <code>Java</code> GUI by making a login system without a database, but my if statement using <code>.equals</code> doesn't work because it always says incorrect password.</p>
  
  <p><code>contains()</code> work but I think it's not that secure </p>
  
  <pre><code>String user = USERNAME.getText();   
  String pass = PASSWORD.getText(); 
  if(user.equals("username") &amp;&amp; pass.equals("password") ){
      JOptionPane.showMessageDialog(null, "Welcome to GUI");
  } else {
      JOptionPane.showMessageDialog(null, "Wrong Username and password");    
  }
  </code></pre>