mirror of
https://gitlab.com/Kwoth/nadekobot.git
synced 2025-09-11 09:48:26 -04:00
- Credentials are now loading from creds.yml
- Removed/commented out obsolete credentials code - Added missing properties to creds.yml - Updated README.md with some tasks and progress
This commit is contained in:
@@ -430,7 +430,7 @@ namespace NadekoBot.Modules.Searches
|
||||
if (!await ValidateQuery(ctx.Channel, name).ConfigureAwait(false))
|
||||
return;
|
||||
|
||||
if (string.IsNullOrWhiteSpace(_creds.MashapeKey))
|
||||
if (string.IsNullOrWhiteSpace(_creds.RapidApiKey))
|
||||
{
|
||||
await ReplyErrorLocalizedAsync("mashape_api_missing").ConfigureAwait(false);
|
||||
return;
|
||||
|
@@ -575,7 +575,7 @@ namespace NadekoBot.Modules.Searches.Services
|
||||
using (var http = _httpFactory.CreateClient())
|
||||
{
|
||||
http.DefaultRequestHeaders.Clear();
|
||||
http.DefaultRequestHeaders.Add("x-rapidapi-key", _creds.MashapeKey);
|
||||
http.DefaultRequestHeaders.Add("x-rapidapi-key", _creds.RapidApiKey);
|
||||
try
|
||||
{
|
||||
var response = await http.GetStringAsync($"https://omgvamp-hearthstone-v1.p.rapidapi.com/" +
|
||||
|
Reference in New Issue
Block a user