title: if statement with text not working
body: <p>I want to use a if statement to open different modals.
  Unfortunately, it do not work. It always open the '#flowSettingsDomain'.
  What´s going wrong? Thank you for your tips.</p>
  
  <p><strong>HTML</strong></p>
  
  <pre><code>&lt;ol class="targetjQEdit ui-sortable flowControllers"&gt;
      &lt;li class="f1"&gt;
          &lt;span class="step"&gt;Language Flow&lt;/span&gt;
          &lt;a href="#" id="lF" class="dismiss"&gt;
              &lt;i class="glyphicon glyphicon-remove-circle"&gt;&lt;/i&gt;
          &lt;/a&gt;
          &lt;a href="#" onclick="fSetting(this); return false;" class="flowSettings"&gt;
              &lt;i class="glyphicon glyphicon-cog"&gt;&lt;/i&gt;
          &lt;/a&gt;
          &lt;span class="badge badgeFilter" id="de"&gt;German&lt;/span&gt;
          &lt;span class="badge badgeFilter" id="en"&gt;English&lt;/span&gt;
      &lt;/li&gt;
      &lt;li class="f1"&gt;
          &lt;span class="step"&gt;Domain Flow&lt;/span&gt;
          &lt;a href="#" id="dF" class="dismiss"&gt;
              &lt;i class="glyphicon glyphicon-remove-circle"&gt;&lt;/i&gt;
          &lt;/a&gt;
          &lt;a href="#" onclick="fSetting(this); return false;" class="flowSettings"&gt;
              &lt;i class="glyphicon glyphicon-cog"&gt;&lt;/i&gt;
          &lt;/a&gt;
          &lt;span class="badge badgeFilter" id="med"&gt;Medicine&lt;/span&gt;
      &lt;/li&gt;
  &lt;/ol&gt;
  </code></pre>
  
  <p><strong>JS</strong></p>
  
  <pre><code>function fSetting (obj) {
      var t = $(obj).closest('span').text();
      tx = $.trim(t);     
      if (tx  == 'Language Flow') {
          $('#flowSettingsLanguage').modal('show');
      } 
      if (tx.contains = 'Domain Flow') {
          $('#flowSettingsDomain').modal('show');
      }
  };
  </code></pre>