[Feature] Sharing should redirect to login page

Open
#5,603 1 comment 0 reactions 0 assignees View on GitHub

Maintainers usually reply within 1 day

Nobody has claimed this yet.

Assessment

Difficulty
3/5
Estimated time
1-2 days
Newbie friendliness
64/100
Issue type
Feature
Clarity
Clearly specified
Activity status
Active
Tech stack
python

Research direction

Start from the route that serves /api/roms/{id}/content for a shared link and find where the unauthenticated request is rejected, then trace how the frontend handles a 401 from that download. Read the auth/login flow and the share-token handling before changing anything, since the redirect must preserve the requested ROM so the download can start after login. Done means an anonymous visit to a share link lands on the login page and the download begins once the user authenticates, without breaking normal authenticated downloads.

Written by the indexing model from the issue text.

Description

When using the "Share" function, you get a download-link like this:

ROMM Share

https://games.***.***/api/roms/550/content/*****.****

When someone who is not logged in opens that link, he gets this not authenticated message:

Not authenticated

I think it would be much cleaner if it would redirect to the login page instead of showing that message.
After logging in, start the download.

Dominant language
Python
Stars
13.3k
Forks
747
Avg merge
20h 58m
Merged PRs (30d)
207

Getting set up

This project ships no dev container, Dockerfile or contributing guide, so setting up is up to you: start from its README, and see our first-contribution guide for the general steps.

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

More from rommapp/romm

All issues in rommapp/romm

Similar issues

More Python issues

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.