This button worked when viewing merge requests because the JavaScript stripped the .html in the Ajax request. However, it left the .html suffix in the compare branch view.