OST_REPO_OWNER is not used for /api/image
vildzi opened this issue · 1 comments
vildzi commented
Provide environment information
ENV Flags Set:
- OST_GITHUB_ID
- OST_GITHUB_SECRET
- OST_TOKEN_SECRET
- OST_REPO_SLUG
- OST_REPO_BRANCH
- OST_REPO_OWNER
What browser are you using? (if relevant)
No response
How are you deploying your application? (if relevant)
No response
Describe the Bug
When a user who is not the owner of the repo (and OST_REPO_OWNER is set) is adding or viewing images in a post, a "Couldn't load image." error occurs.
Expected Behavior
OST_REPO_OWNER should be used when getting images from raw.githubusercontent.com
if set rather than always using the current users username.
Link to reproduction - Issues with a link to complete (but minimal) reproduction code will be addressed faster
N/A - any deployment with OST_REPO_OWNER set will work to reproduce the issue
To Reproduce
- Log in to outstatic as a user who is not the owner of the repo
- Attach an image to a post