title: How to use pass nil to URL in SDWebImage with Swift
body: <p>I am using <code>SDWebImage</code> function in a <code>Swift</code> controller. </p>
  
  <pre><code>sd_setImageWithURL:(NSURL *)url placeholderImage:(UIImage *)placeholder completed:(SDWebImageCompletionBlock)completedBlock;
  </code></pre>
  
  <p>in swift it is displaying as</p>
  
  <pre><code>let url  = NSURL(string:ventModel.backgroundBlurredURL)
  let img = UIImage(named: "")
  cell.courseImgView.sd_setImageWithURL(url, placeholderImage: img) { (UIImage img, NSError err, SDImageCacheType cacheType, NSURL imgUrl) -&gt; Void in
  
      }
  </code></pre>
  
  <p>Now lets say in my model i.e. <code>ventModel</code> I cannot get a imageURL i.e. nil. So the app will give a fatal error and crashes. </p>