Skip to content
This repository has been archived by the owner on Nov 14, 2024. It is now read-only.

Commit

Permalink
Update 4anime server recommendations
Browse files Browse the repository at this point in the history
  • Loading branch information
SuperMarcus committed Dec 11, 2019
1 parent e376758 commit e7d47f6
Showing 1 changed file with 9 additions and 0 deletions.
9 changes: 9 additions & 0 deletions NineAnimator/Models/Anime Source/4anime.to/FourAnime.swift
Original file line number Diff line number Diff line change
Expand Up @@ -58,6 +58,15 @@ class NASourceFourAnime: BaseSource, Source, PromiseSource {
? DummyParser.registeredInstance : nil
}

override func recommendServer(for anime: Anime) -> Anime.ServerIdentifier? {
return recommendServers(for: anime, ofPurpose: .playback).first
}

override func recommendServers(for anime: Anime, ofPurpose purpose: VideoProviderParserParsingPurpose) -> [Anime.ServerIdentifier] {
return anime.servers.keys.contains(NASourceFourAnime.FourAnimeStream)
? [NASourceFourAnime.FourAnimeStream] : []
}

func link(from url: URL) -> NineAnimatorPromise<AnyLink> {
return .fail()
}
Expand Down

0 comments on commit e7d47f6

Please sign in to comment.