Added database table data into configuration. Store saves is auto-handled. Added Action & Redemption stores.
This commit is contained in:
@@ -1,3 +1,4 @@
|
||||
using HermesSocketLibrary.Requests.Messages;
|
||||
using HermesSocketServer.Models;
|
||||
using HermesSocketServer.Store;
|
||||
using ILogger = Serilog.ILogger;
|
||||
@@ -8,7 +9,7 @@ namespace HermesSocketServer.Requests
|
||||
{
|
||||
public string Name => "update_tts_voice";
|
||||
public string[] RequiredKeys => ["voice", "voiceId"];
|
||||
private IStore<string, Voice> _voices;
|
||||
private IStore<string, TTSVoice> _voices;
|
||||
private ILogger _logger;
|
||||
|
||||
public UpdateTTSVoice(VoiceStore voices, ILogger logger)
|
||||
@@ -22,7 +23,7 @@ namespace HermesSocketServer.Requests
|
||||
string voiceName = data["voice"].ToString()!;
|
||||
string voiceId = data["voiceid"].ToString()!;
|
||||
|
||||
var result = _voices.Set(voiceId, new Voice()
|
||||
var result = _voices.Set(voiceId, new TTSVoice()
|
||||
{
|
||||
Id = voiceId,
|
||||
Name = voiceName
|
||||
|
||||
Reference in New Issue
Block a user