title: Block stored as instance variable becomes nil
body: <p>I'm trying to store a block in an instance variable in my project.  Here's where I declare the instance variable:</p>
  
  <pre><code>@property (nonatomic, copy)void (^loginCompletedTask)();
  </code></pre>
  
  <p>I'm assigning the variable by calling this method:</p>
  
  <pre><code>- (void)requireLoggedInForBlock:(void (^)())completion {
      self.loginCompletedTask = completion;
  
      // Display an alert view that requires username and password input
  }
  </code></pre>
  
  <p>After the first line of this method, <code>self.loginCompletedTask</code> is non-nil and logs in the debugger with type <code>NSMallocBlock</code>.  However, when I actually need to run the block after the login alert view is returned, it has become nil.</p>
  
  <p>I've tried:</p>
  
  <ul>
  <li>Declaring with <code>strong</code> instead of <code>copy</code>,</li>
  <li>Setting as <code>self.loginCompletedTask = ^{completion();};</code>,</li>
  <li>Setting the variable directly, instead of using a property (<code>_loginCompletedTask = ...</code>).</li>
  </ul>
  
  <p>What am I missing?</p>