feat: enforce strict mal id in allanime getstreams

This commit is contained in:
2026-07-01 18:53:19 +02:00
parent 223c0fa89e
commit 2918fa5051
3 changed files with 27 additions and 32 deletions

View File

@@ -55,8 +55,8 @@ func (c *AllAnimeProvider) apiBaseURL() string {
}
func (c *AllAnimeProvider) GetStreams(ctx context.Context, animeID int, titleCandidates []string, episode string, mode string) (*domain.StreamResult, error) {
showID := c.showID(ctx, animeID, titleCandidates, mode)
if showID == "" {
showID, err := c.strictShowID(ctx, animeID, titleCandidates, mode)
if err != nil {
return nil, fmt.Errorf("allanime: show not found for malID %d", animeID)
}