예제 #1
0
        public async Task <string> Download(string PosterPath)
        {
            var sourceToken = new CancellationTokenSource();
            var localPath   = _download.LocalPathForFilename(PosterPath);

            if (_download.DoesPathExist(PosterPath))
            {
                sourceToken.Cancel();
            }
            await _download.DownloadImage(PosterPath, localPath, sourceToken.Token);

            return(localPath);
        }