diff options
Diffstat (limited to 'Services/ConfigService.cs')
| -rw-r--r-- | Services/ConfigService.cs | 14 |
1 files changed, 9 insertions, 5 deletions
diff --git a/Services/ConfigService.cs b/Services/ConfigService.cs index 8460fd0..d2d1a06 100644 --- a/Services/ConfigService.cs +++ b/Services/ConfigService.cs @@ -1,11 +1,12 @@ namespace HyperBooru.Services; public interface IConfigService { - public string DataPath { get; } - public string DbConnectionString { get; } - public string MediaBasePath { get; } - public string ThumbnailBasePath { get; } - public bool EnableOcr { get; } + public string DataPath { get; } + public string DbConnectionString { get; } + public string MediaBasePath { get; } + public string ThumbnailBasePath { get; } + public string ConvertedMediaBasePath { get; } + public bool EnableOcr { get; } } public class ConfigService : IConfigService { @@ -47,6 +48,9 @@ public class ConfigService : IConfigService { public string ThumbnailBasePath => Path.Join(DataPath, "thumb"); + public string ConvertedMediaBasePath => + Path.Join(DataPath, "converted"); + public bool EnableOcr => bool.TryParse(config["DisableOcr"], out bool x) ? !x : true; |
