Remove or replace unused favorites API and middleware code

Aperta
#265 0 commenti 0 reazioni 0 assegnatari Vedi su GitHub

I maintainer di solito rispondono entro 1 giorno

Nessuno ha ancora preso questa issue.

Valutazione

Difficoltà
3/5
Tempo stimato
1-2 giorni
Idoneità per principianti
65/100
Tipo di issue
Refactoring
Chiarezza
Abbastanza chiara
Stato di attività
Attiva
Stack tecnologico
next.js, typescript

Direzione di ricerca

Start by searching the repository for uses of the favorites helpers in src/services/api.tsx and the /user/favorites middleware match in middleware.ts; audit src/models/user.ts without removing unrelated user data. Compare any remaining callers with the /api/timetables routes and saved-timetable flow. Done when dead favorites code is removed, or dependent callers use the supported API with server-side auth enforced.

Scritto dal modello di indicizzazione a partire dal testo della issue.

Descrizione

enhancement good first issue

There's still some old favorites-related code that doesn't seem to match the current saved-timetable flow.

src/services/api.tsx calls /api/user/favorites, but that route isn't present in the current tree. middleware.ts also matches /user/favorites, while saved timetables now live under /saved and the /api/timetables routes.

Please check whether anything still uses these helpers. If not, remove the dead code and obsolete middleware. If something does depend on them, move it to the supported saved-timetables API and make sure auth remains enforced server-side.

Files: src/services/api.tsx, middleware.ts, src/models/user.ts (audit only — don't delete unrelated user data/models).

Lingua principale
TypeScript
Stelle
7
Fork
39
Merge medio
4h 24m
PR unite (30g)
53

Preparare l'ambiente

Come iniziare

  1. Leggi tutta la issue e poi la guida ai contributi del progetto.
  2. Commenta sulla issue per dire che te ne occupi tu — evita che due persone facciano lo stesso lavoro.
  3. Fai un fork del repository e lavora su un branch.
  4. Apri una pull request che faccia riferimento al numero della issue.

Altre issue di CodeChefVIT/ffcs

Tutte le issue di CodeChefVIT/ffcs

Issue simili

Altre issue su TypeScript

Ricevi le nuove issue nella tua casella

Un breve riepilogo di issue GitHub adatte ai principianti.