public override Task <Tuple <bool, INuGetResource> > TryCreate(SourceRepository source, CancellationToken token) { HttpHandlerResourceV3 curResource = null; #if !DNXCORE50 // Everyone gets a dataclient var HttpHandler = TryGetCredentialAndProxy(source.PackageSource) ?? DataClient.DefaultHandler; curResource = new HttpHandlerResourceV3(HttpHandler); #endif return(Task.FromResult(new Tuple <bool, INuGetResource>(curResource != null, curResource))); }
public override async Task<Tuple<bool, INuGetResource>> TryCreate(SourceRepository source, CancellationToken token) { HttpHandlerResourceV3 curResource = null; #if !DNXCORE50 // Everyone gets a dataclient var HttpHandler = TryGetCredentialAndProxy(source.PackageSource) ?? DataClient.DefaultHandler; curResource = new HttpHandlerResourceV3(HttpHandler); #endif return new Tuple<bool, INuGetResource>(curResource != null, curResource); }