Skip to content

Conversation

@artonge
Copy link
Collaborator

@artonge artonge commented Oct 18, 2022

Follow up of #1341 as currentUser is null on public pages

@artonge artonge added the 3. to review Waiting for reviews label Oct 18, 2022
@artonge artonge added this to the Nextcloud 26 milestone Oct 18, 2022
@artonge artonge requested a review from skjnldsv October 18, 2022 15:33
@artonge artonge self-assigned this Oct 18, 2022
@artonge artonge added the bug Something isn't working label Oct 18, 2022
@artonge
Copy link
Collaborator Author

artonge commented Oct 18, 2022

/backport to stable25

@backportbot-nextcloud backportbot-nextcloud bot added the backport-request Pending backport by the backport-bot label Oct 18, 2022
@skjnldsv
Copy link
Member

Won't that go 💥 if we throw?

@artonge
Copy link
Collaborator Author

artonge commented Oct 18, 2022

Won't that go boom if we throw?

Same if we don't, but at least there is an error message, no ?

import { getCurrentUser } from '@nextcloud/auth'

export const rootPath = 'dav'
export const prefixPath = `/files/${getCurrentUser().uid}`
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

What about just

Suggested change
export const prefixPath = `/files/${getCurrentUser().uid}`
export const prefixPath = `/files/${getCurrentUser()?.uid}`

And we don't touch the other files?

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

True see: #1372

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Sorry 🙈

@artonge artonge closed this Oct 18, 2022
@skjnldsv skjnldsv deleted the artonge/fix/public_albums_access branch January 7, 2025 08:54
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

3. to review Waiting for reviews backport-request Pending backport by the backport-bot bug Something isn't working

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants