random stuff
This commit is contained in:
parent
1b96e520e7
commit
7695112232
BIN
NadekoBot/Classes/lib/ScaredFingers.UnitsConversion.dll
Normal file
BIN
NadekoBot/Classes/lib/ScaredFingers.UnitsConversion.dll
Normal file
Binary file not shown.
BIN
NadekoBot/Classes/lib/ScaredFingers.UnitsConversion.pdb
Normal file
BIN
NadekoBot/Classes/lib/ScaredFingers.UnitsConversion.pdb
Normal file
Binary file not shown.
@ -28,15 +28,6 @@ namespace NadekoBot.Modules.Translator.Helpers
|
||||
return GoogleTranslator._languageModeMap.Keys.OrderBy(p => p);
|
||||
}
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// Gets the error.
|
||||
/// </summary>
|
||||
public Exception Error {
|
||||
get;
|
||||
private set;
|
||||
}
|
||||
|
||||
#endregion
|
||||
|
||||
#region Public methods
|
||||
@ -66,7 +57,7 @@ namespace NadekoBot.Modules.Translator.Helpers
|
||||
using (HttpClient http = new HttpClient())
|
||||
{
|
||||
http.DefaultRequestHeaders.Add("user-agent", "Mozilla/5.0 (Windows NT 6.1) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/41.0.2228.0 Safari/537.36");
|
||||
text = await http.GetStringAsync(url);
|
||||
text = await http.GetStringAsync(url).ConfigureAwait(false);
|
||||
}
|
||||
|
||||
return JArray.Parse(text)[0][0][0].ToString();
|
||||
|
@ -31,7 +31,7 @@ namespace NadekoBot.Modules.Translator
|
||||
if (string.IsNullOrWhiteSpace(text))
|
||||
return;
|
||||
|
||||
string translation = await t.Translate(text, from, to);
|
||||
string translation = await t.Translate(text, from, to).ConfigureAwait(false);
|
||||
await e.Channel.SendMessage(translation).ConfigureAwait(false);
|
||||
}
|
||||
catch (Exception ex)
|
||||
|
@ -134,6 +134,7 @@
|
||||
<Reference Include="System.Xml" />
|
||||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
<Compile Include="Classes\ObservableConcurrentDictionary.cs" />
|
||||
<Compile Include="Modules\Administration\Commands\AutoAssignRole.cs" />
|
||||
<Compile Include="Modules\Administration\Commands\CustomReactionsCommands.cs" />
|
||||
<Compile Include="Modules\Administration\Commands\SelfAssignedRolesCommand.cs" />
|
||||
@ -496,7 +497,7 @@
|
||||
</ProjectReference>
|
||||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
<Content Include="lib\ScaredFingers.UnitsConversion.dll" />
|
||||
<Content Include="Classes\lib\ScaredFingers.UnitsConversion.dll" />
|
||||
<None Include="resources\images\rose_overlay.png" />
|
||||
</ItemGroup>
|
||||
<ItemGroup />
|
||||
|
Loading…
Reference in New Issue
Block a user