Allow caching of negative FindCommit matches
When FindCommit
ref caching is enabled, negative matches would
previously not be cached. However, if a source branch is deleted,
there's no need to keep looking up the same commit. This change caches
the result of a nil commit.
Edited by Stan Hu