Fix Compare page throws 500 error when any branch/reference is not selected
What does this MR do?
It fixes the error documented in this URL: https://gitlab.com/gitlab-org/gitlab-ce/issues/25814
Are there points in the code the reviewer needs to double check?
No
Why was this MR needed?
It was a listed Issue: https://gitlab.com/gitlab-org/gitlab-ce/issues/25814
Screenshots (if relevant)
Does this MR meet the acceptance criteria?
-
Changelog entry added -
Documentation created/updated -
API support added - Tests
-
Added for this feature/bug -
All builds are passing
-
-
Conform by the merge request performance guides -
Conform by the style guides -
Branch has no merge conflicts with master
(if it does - rebase it please) -
Squashed related commits together