Code: Select all
[Command("jpg")]
private async Task Jpg([Remainder] string text)
{
string filetype = Path.GetExtension(text);
if (!text.StartsWith("http") || !text.StartsWith("https"))
{
return;
}
using (var client = new WebClient())
{
client.DownloadFileAsync(new Uri(text), "img\\a" + filetype);
}
/* Image stuff etc */
}
Mobile version