using System.Threading.Tasks; using BTCPayServer.Abstractions.Contracts; using BTCPayServer.Services; namespace BTCPayServer { public static class SettingsRepositoryExtensions { public static async Task GetPolicies(this ISettingsRepository settingsRepository) { return await settingsRepository.GetSettingAsync() ?? new PoliciesSettings(); } public static async Task GetTheme(this ISettingsRepository settingsRepository) { return await settingsRepository.GetSettingAsync() ?? new ThemeSettings(); } } }