Skip to content

Commit

Permalink
Removed Lithiio unsupported upload urls
Browse files Browse the repository at this point in the history
  • Loading branch information
Jaex committed Oct 15, 2016
1 parent a948c6f commit 76b4612
Show file tree
Hide file tree
Showing 4 changed files with 2,896 additions and 2,984 deletions.
5 changes: 1 addition & 4 deletions ShareX.UploadersLib/FileUploaders/Lithiio.cs
Original file line number Diff line number Diff line change
Expand Up @@ -64,18 +64,16 @@ public Lithiio(LithiioSettings config)

private const string uploadUrl = "http://api.lithi.io/v3/";

public static string[] UploadURLs = new string[] { "https://i.lithi.io/", "https://lithi.io/i/", "https://i.mugi.io/", "https://mugi.io/i/" };

public override UploadResult Upload(Stream stream, string fileName)
{
Dictionary<string, string> arguments = new Dictionary<string, string>();
arguments.Add("key", Config.UserAPIKey);
arguments.Add("linktype", Config.UploadURL);
UploadResult result = UploadData(stream, uploadUrl, fileName, "file", arguments);

if (result.IsSuccess)
{
LithiioResponse response = JsonConvert.DeserializeObject<LithiioResponse>(result.Response);

if (response.Success)
{
result.URL = response.URL;
Expand All @@ -100,6 +98,5 @@ public class LithiioResponse
public class LithiioSettings
{
public string UserAPIKey { get; set; } = "";
public string UploadURL { get; set; } = "https://i.lithi.io/";
}
}
Loading

0 comments on commit 76b4612

Please sign in to comment.