Remove deprecated functions

Removed global default scraper
This commit is contained in:
Alexander Sheiko 2023-05-11 14:15:56 +03:00
parent 3eb86161ce
commit 66780eb801
5 changed files with 0 additions and 56 deletions

View file

@ -11,21 +11,11 @@ func (s *Scraper) SearchTweets(ctx context.Context, query string, maxTweetsNbr i
return getTweetTimeline(ctx, query, maxTweetsNbr, s.FetchSearchTweets)
}
// Deprecated: SearchTweets wrapper for default Scraper
func SearchTweets(ctx context.Context, query string, maxTweetsNbr int) <-chan *TweetResult {
return defaultScraper.SearchTweets(ctx, query, maxTweetsNbr)
}
// SearchProfiles returns channel with profiles for a given search query
func (s *Scraper) SearchProfiles(ctx context.Context, query string, maxProfilesNbr int) <-chan *ProfileResult {
return getUserTimeline(ctx, query, maxProfilesNbr, s.FetchSearchProfiles)
}
// Deprecated: SearchProfiles wrapper for default Scraper
func SearchProfiles(ctx context.Context, query string, maxProfilesNbr int) <-chan *ProfileResult {
return defaultScraper.SearchProfiles(ctx, query, maxProfilesNbr)
}
// getSearchTimeline gets results for a given search query, via the Twitter frontend API
func (s *Scraper) getSearchTimeline(query string, maxNbr int, cursor string) (*timeline, error) {
if !s.isLogged {