From 6c06dfc4f83f30292e65c08a3cb0c48401d4bfa7 Mon Sep 17 00:00:00 2001 From: Jake Mannens Date: Wed, 25 Mar 2026 01:57:19 +1100 Subject: v0.2a --- Services/ConfigService.cs | 4 ++++ 1 file changed, 4 insertions(+) (limited to 'Services/ConfigService.cs') diff --git a/Services/ConfigService.cs b/Services/ConfigService.cs index b42b80c..8460fd0 100644 --- a/Services/ConfigService.cs +++ b/Services/ConfigService.cs @@ -5,6 +5,7 @@ public interface IConfigService { public string DbConnectionString { get; } public string MediaBasePath { get; } public string ThumbnailBasePath { get; } + public bool EnableOcr { get; } } public class ConfigService : IConfigService { @@ -46,6 +47,9 @@ public class ConfigService : IConfigService { public string ThumbnailBasePath => Path.Join(DataPath, "thumb"); + public bool EnableOcr => + bool.TryParse(config["DisableOcr"], out bool x) ? !x : true; + public ConfigService(IConfiguration config) { this.config = config; InitDirectoryStructure(); -- cgit v1.3