angular/angular.js — pull request #9472 by tbosch (2014-10-07 18:21:25+00:00)
Title: refactor($location): remove special case for adding a `#` at end of url

Previously, `LocationHashbangInHtml5Url` always added a trailing `#`
to the absolute url that was given to `$browser.url` to prevent page reloads
when the hash fragment was empty.

This refactoring adds a general mechanism in `$browser` to ignore
a trailing `#` during read and add a trailing `#` when the hash fragment
is removed.