title: What is the right way to check for a null string in Objective-C?
body: <p>I was using this in my iPhone app</p>
  
  <pre><code>if (title == nil) {
      // do something
  }
  </code></pre>
  
  <p>but it throws some exception, and the console shows that the title is "(null)".</p>
  
  <p>So I'm using this now:</p>
  
  <pre><code>if (title == nil || [title isKindOfClass:[NSNull class]]) {
      //do something
  }
  </code></pre>
  
  <p>What is the difference, and what is the best way to determine whether a string is null?</p>