Fix NPE
Fix NPE

Although it seems strange to have a RefModel with a referenced object
but a null Ref, Gitblit uses such RefModels for instance in
JGitUtils.getNotesOnCommit().

Be careful to do something sensible when that Ref is null.

fzs/gitblit,fzs/gitblit,gitblit/gitblit,gitblit/gitblit,fzs/gitblit,gitblit/gitblit,fzs/gitblit,gitblit/gitblit,gitblit/gitblit,fzs/gitblit