title: Check if two consts are empty
body: <p>I'm kind of new to the C++ scene so I'm wondering how I'd verify both fields have some text entered, here's the current code which is only verifying one field</p>
  
  <pre><code>void App::requestLogin(const QString &amp;email, const QString &amp;password) {
      if (m_active)
          return;
  
      //how can I do both password and email here????
      const QStringList list = email.split(QRegExp("\\s+"), QString::SkipEmptyParts);
      if (list.isEmpty()) {
          m_errorMessage = "please complete both fields";
          m_error = true;
          emit statusChanged();
          return;
      }
  }
  </code></pre>