diff options
author | Douwe Maan <douwe@gitlab.com> | 2015-10-15 07:26:39 +0000 |
---|---|---|
committer | Douwe Maan <douwe@gitlab.com> | 2015-10-15 07:26:39 +0000 |
commit | 7ad685236344f129d173c2d5487fa9291d3c0bc9 (patch) | |
tree | da9f8c43d364f95a807ac9c243e499fda504f8d4 /lib/api/projects.rb | |
parent | 976400c1e6c653ce93cd29d32a007c091a38f970 (diff) | |
parent | fc0d92746d8a228077c6602be1f77b679f5d196a (diff) | |
download | gitlab-ce-7ad685236344f129d173c2d5487fa9291d3c0bc9.tar.gz |
Merge branch 'rs-mr-tabs-scroll' into 'master'
Prevent a JS error in MergeRequestTabs
When `window.location.hash` is pointing to a note, e.g. `#note_1234`,
`scrollToElement` would throw an error because a selector such as
`.commits #note_1234` doesn't exist, so `offset()` returned `undefined`.
This error would prevent subsequent calls from running, which caused the
loading spinner to never be hidden.
Now we ensure the selector returns a valid element before trying to
scroll to it.
This is the proper fix for !1553.
See merge request !1597
Diffstat (limited to 'lib/api/projects.rb')
0 files changed, 0 insertions, 0 deletions