Skip to content

Commit

Permalink
Fix space image with blank space not shown (#6881)
Browse files Browse the repository at this point in the history
Decode uri
  • Loading branch information
Jan authored May 5, 2022
1 parent 16bb710 commit cc799da
Show file tree
Hide file tree
Showing 2 changed files with 12 additions and 0 deletions.
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
Bugfix: Space image not shown if file name contains blanks

https://github.com/owncloud/web/pull/6881
https://github.com/owncloud/web/issues/6874
8 changes: 8 additions & 0 deletions packages/web-app-files/src/helpers/resources.ts
Original file line number Diff line number Diff line change
Expand Up @@ -120,6 +120,14 @@ export function buildSpace(space) {
if (space.special) {
spaceImageData = space.special.find((el) => el.specialFolder.name === 'image')
spaceReadmeData = space.special.find((el) => el.specialFolder.name === 'readme')

if (spaceImageData) {
spaceImageData.webDavUrl = decodeURI(spaceImageData.webDavUrl)
}

if (spaceReadmeData) {
spaceReadmeData.webDavUrl = decodeURI(spaceReadmeData.webDavUrl)
}
}

if (space.root?.permissions) {
Expand Down

0 comments on commit cc799da

Please sign in to comment.