Repository navigation
Fix media-viewer on private pages - #3288
Conversation
|
Thanks for opening this pull request! The maintainers of this repository would appreciate it if you would create a changelog item based on your changes. |
000ca0c to
fb1c979
Compare
|
Should we close this PR since it's included in #3294 ? |
|
It depends on the chances you see for the other PR to land soon :-) This is the bare minimum the app needs to work at all, merging it gives us at least a roughly working app. However you like. |
|
@dschmidt I approved the PR so feel free to merge it if you feel like it should get merged before the other PR since I am not sure how long that one will take before merging. |
|
Yep, merging! :-) And yes, full ack. It's messy and should be fixed properly in a central place. I just don't know phoenix well enough yet to have an opinion how and where it should be fixed. For now we at least have a working mediaviewer again :-) |
Description
I've made the mediaviewer app depend only on this.isAuthenticated instead of this.publicPage().
publicPage() is always true because (at least I assume so) it's rendered in its own route that is always public. In my tests I could use isAuthenticated to determine whether it was loaded from a private page or from a public link e.g.
It feels hackish, happy to hear if there's a better API to use.
Related Issue
Motivation and Context
How Has This Been Tested?
Screenshots (if appropriate):
Types of changes
Checklist: