mirror of https://github.com/pikami/tiktok-dl.git
20 lines
405 B
Go
20 lines
405 B
Go
package utils
|
|
|
|
import (
|
|
resources "github.com/pikami/tiktok-dl/resources"
|
|
fileio "github.com/pikami/tiktok-dl/utils/fileio"
|
|
)
|
|
|
|
// GetScraper - Retrieve scraper
|
|
func GetScraper() string {
|
|
if fileio.CheckIfExists(resources.ScraperPath) {
|
|
return ReadFileAsString(resources.ScraperPath)
|
|
}
|
|
|
|
if resources.ScraperScript != "" {
|
|
return resources.ScraperScript
|
|
}
|
|
|
|
panic(resources.FailedToLoadScraper)
|
|
}
|