Unchecking "Show whitespace changes" when comparing changes in large merge request causes page to not respond
Summary
When looking at the changes for a large merge request, clicking the gear and unchecking "Show whitespace changes" causes the page to freeze and eventually not respond. If you add ?w=1 to the url it is instant to load.
Steps to reproduce
- Go to large merge request
- Go to "Changes" tab
- Click gear icon
- Toggle "Show whitespace changes"
- Wait and eventually kill page and reload to get it to work again
What is the current bug behavior?
Page stops responding
What is the expected correct behavior?
Page should hide whitespace changes, even if it has to reload
Possible fixes
If the page takes too long to toggle showing whitespace changes (or if the request has too many files or changed lines), it should just reload itself with the new setting.