title: Swift optionals nil check
body: <p>So I fail to figure a 1 liner for following syntax in Swift and it is driving me nuts:</p>
  
  <pre><code>if lastProfile == nil || lastProfile.id == profile.id {
          useProfile(profile)
          lastProfile = profile
  }
  </code></pre>
  
  <p>Now see I could chain it but I'd still end up with 2-3 ifs. I could pack it out but then I again end up with 2-3 ifs... Is it possible to do this in just 1 swoop?</p>
  
  <p>Edit: </p>
  
  <p>My colleague found an alternative (although we agree ugly):</p>
  
  <pre><code>if !(latestProfile != nil &amp;&amp; latestProfile!.voiceId != profile.voiceId) {
  
  }
  </code></pre>
  
  <p>Is there a better approach than above?</p>