mirror of
https://gitlab.com/Kwoth/nadekobot.git
synced 2025-09-13 18:58:27 -04:00
- small bot.cs cleanup
- creds.yml now loads and reloads properly (from the current directory, like credentials.json) - added empty creds.yml to repo, and added it to .gitignore
This commit is contained in:
@@ -8,6 +8,7 @@ using NadekoBot.Services;
|
||||
using NadekoBot.Modules.Administration.Services;
|
||||
using NadekoBot.Modules.Music.Resolvers;
|
||||
using NadekoBot.Modules.Music.Services;
|
||||
using StackExchange.Redis;
|
||||
|
||||
namespace NadekoBot.Extensions
|
||||
{
|
||||
@@ -65,5 +66,12 @@ namespace NadekoBot.Extensions
|
||||
|
||||
return services;
|
||||
}
|
||||
|
||||
public static IServiceCollection AddRedis(this IServiceCollection services, string redisOptions)
|
||||
{
|
||||
var conf = ConfigurationOptions.Parse(redisOptions);
|
||||
services.AddSingleton(ConnectionMultiplexer.Connect(conf));
|
||||
return services;
|
||||
}
|
||||
}
|
||||
}
|
Reference in New Issue
Block a user