title: Branch exists but cannot be seen in refs/heads
body: <p>In a bare repository (no working folder) on a BitBucket Server machine, I have two release branches:</p>
  
  <pre><code># git branch --list | grep release
  warning: ignoring broken ref refs/heads/integration/Team
    release/2018r1
    release/2018r2
  </code></pre>
  
  <p>But if I look in <code>refs/heads</code>, neither of these branches can be seen:</p>
  
  <pre><code># ls refs/heads/release
  testing
  </code></pre>
  
  <p>The <code>testing</code> branch is a branch that was deleted some time ago.</p>
  
  <p>How is it possible for <code>release/2018r1</code> and <code>release/2018r2</code> to exist (and be seen by <code>git branch --list</code>) but not show up in <code>refs/heads</code>?</p>
  
  <p>And why does the old <code>release/testing</code> branch show up in <code>refs/heads</code>, when it doesn't exist anymore?</p>