Reorder enum

Some more work on gcs
This commit is contained in:
Matthew Burnett 2018-04-19 17:48:59 -04:00
parent 233d822c24
commit bfdede32eb
2 changed files with 8 additions and 6 deletions

View file

@ -99,10 +99,10 @@ public enum FileDestination
Mega,
[Description("Amazon S3")]
AmazonS3,
[Description("Azure Storage")]
AzureStorage,
[Description("Google Cloud Storage")]
GoogleCloudStorage,
[Description("Azure Storage")]
AzureStorage,
[Description("Gfycat")]
Gfycat,
[Description("ownCloud / Nextcloud")]

View file

@ -24,13 +24,15 @@ public override GenericUploader CreateUploader(UploadersConfig config, TaskRefer
public sealed class GoogleCloudStorage : FileUploader
{
public string APIKey { get; set; }
public string bucket { get; set; }
public override UploadResult Upload(Stream stream, string fileName)
{
Dictionary<string, string> args = new Dictionary<string, string>
{
{ "key", APIKey }
};
string uploadurl = $"https://www.googleapis.com/upload/storage/v1/b/{bucket}/o";
string objecturl = $"https://www.googleapis.com/upload/storage/v1/b/{bucket}/o/{fileName}/acl";
Dictionary<string, string> args = new Dictionary<string, string>();
args.Add("key", APIKey);
return null;
}