mirror of
https://github.com/MindWorkAI/AI-Studio.git
synced 2026-11-04 18:47:21 +00:00
Added backups of all data, restorable on another computer (#1008)
Co-authored-by: Thorsten Sommer <SommerEngineering@users.noreply.github.com>
This commit is contained in:
1 parent
ab45580473
commit
936043319c
144 files changed
+10417
-424
No files matched your search
@@ -0,0 +1,16 @@
|
||||
using AIStudio.Tools.Services;
|
||||
|
||||
namespace AIStudio.Tools.DataBackup;
|
||||
|
||||
/// <summary>
|
||||
/// Asks the runtime whether the OS keyring holds a secret. It only tries, so a missing secret logs no error.
|
||||
/// </summary>
|
||||
/// <param name="rustService">The runtime.</param>
|
||||
public sealed class RustStoredSecrets(RustService rustService) : IStoredSecrets
|
||||
{
|
||||
/// <inheritdoc />
|
||||
public async Task<bool> HasAPIKeyAsync(ISecretId secretId, SecretStoreType storeType) => (await rustService.GetAPIKey(secretId, storeType, isTrying: true)).Success;
|
||||
|
||||
/// <inheritdoc />
|
||||
public async Task<bool> HasSecretAsync(ISecretId secretId, SecretStoreType storeType) => (await rustService.GetSecret(secretId, storeType, isTrying: true)).Success;
|
||||
}
|
||||
Reference in new issue
Block a user