Photo view: More menu shows when it shouldn't
nicokaiser opened this issue · comments
The "more" menu shows in some occasions when it should be hidden, e.g. when an album is public, but the photos are not downloadable and not viewable in full resolution.
There seems to be some kind of logic error in the Hide More menu if
in header.js.
The "more" menu is still shown when a high resolution file is available, but the user does not have access to it.
I'm not sure, but maybe the last condition in https://github.com/LycheeOrg/Lychee-front/pull/388/files#diff-ce19eb9f2702730c73073626eafe662bdd03644cd16bc5095f897241c5c37785R505 (|| photo.json.size_variants.original.url
) needs to be removed from the statement?
Indeed photo.json.size_variants.original.url
is supposed to always exists, what needs to be checked is whether the value in it is not empty. We have a downgrade code which will erase this value in the backend if full photo is not available (in theory).
Also we now have photo.json.rights.can_access_full_photo
which is supposed to inform those details.