Defect #32449
closedDiff view for .js files in repositories is broken
Description
When viewing a commit in the repository for a non-javascript file, clicking the diff link for that file opens the diff in the "view differences" tab on the same page.
When viewing a javascript file with a .js extension, clicking the diff link opens the snippet that would normally go in the "view differences" as a new page with no styling.
This is happening on our install across projects and consistently for all javascript files. Clicking on the "view differences" table for the javascript files instead of the diff link does display normally. It is easy to work around, by just using the show differences tab instead of the diff link.
Environment:
Redmine version 4.0.5.stable
Ruby version 2.6.3-p62 (2019-04-16) [x86_64-linux]
Rails version 5.2.3
Environment production
Database adapter Mysql2
Mailer queue ActiveJob::QueueAdapters::AsyncAdapter
Mailer delivery smtp
SCM:
Git 2.17.1
Files

