1
0
Fork 0
mirror of https://codeberg.org/forgejo/forgejo.git synced 2025-09-15 18:56:59 +00:00

[GITEA] Fix generated source URL on rendered files

- The permalink and 'Reference in New issue' URL of an renderable
file (those where you can see the source and a rendered version of it,
such as markdown) doesn't contain `?display=source`. This leads the
issue that the URL doesn't have any effect, as by default the rendered
version is shown and thus not the source.
- Add `?display=source` to the permalink URL and to 'Reference in New Issue' if it's renderable file.
- Add integration testing.

(cherry picked from commit 458f20f862)
This commit is contained in:
Gusted 2023-07-21 21:04:05 +02:00 committed by Earl Warren
parent 9753c7e4b8
commit 5e630d7b10
No known key found for this signature in database
GPG key ID: 0579CB2928A78A00
3 changed files with 50 additions and 2 deletions

View file

@ -607,3 +607,15 @@
repo_id: 52
type: 1
created_unix: 946684810
-
id: 91
repo_id: 49
type: 1
created_unix: 946684810
-
id: 92
repo_id: 49
type: 2
created_unix: 946684810