Baseflow / Baseflow/flutter_cache_manager

Cache 204 - No content

Aperta
#333 7 commenti 0 reazioni 0 assegnatari Vedi su GitHub
type: enhancement
Lingua principale
Dart
Stelle
809
Fork
510
Merge medio
6m
PR unite (30g)
1

Descrizione

## 💬 Questions and Help

If I understand the code correctly currently only 200 and 202 status codes are added to the cache.

https://github.com/Baseflow/flutter_cache_manager/blob/c7881776325441f3900277499615981c40d12284/flutter_cache_manager/lib/src/web/web_helper.dart#L23-L24

In my case I have a image API endpoint which *tries* to generate a image/logo/etc. based on a user-provided website URL. Since the user input could just as well be an internal URL or just broken, it is perfectly fine for the endpoint to return a 404 response. Right now this is not cached on the client side but requested every time.

Is this the intended behavior, or any way to cache non-existent URLs?

Guida per i contributori

Apri la guida per i contributori

Direzione di ricerca

Read lib/src/web/web_helper.dart at the linked lines to confirm which HTTP status codes are currently cached. Clarify whether the requested behavior covers 204, 404, or other non-success responses, then verify that the selected behavior prevents repeated requests for the reported image API case.

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

Valutazione

Stack tecnologico
dart
Ambito
mobile-dev, performance
Tipo di issue
Funzionalità
Difficoltà
3/5
Tempo stimato
1-2 giorni
Stato di attività
Ferma
Chiarezza
Abbastanza chiara
Idoneità per principianti
35/100

Ricevi le nuove issue nella tua casella

Un breve riepilogo di issue GitHub adatte ai principianti.