diff --git a/demo/App.config b/demo/App.config
index bfe70c7..a13afe7 100644
--- a/demo/App.config
+++ b/demo/App.config
@@ -95,8 +95,13 @@
+
+
+
+
+
-
+
\ No newline at end of file
diff --git a/demo/Program.cs b/demo/Program.cs
index 2a0236a..ac681fa 100644
--- a/demo/Program.cs
+++ b/demo/Program.cs
@@ -16,8 +16,12 @@
namespace ConsoleClient
{
internal sealed class Program
- {
- private static readonly ICoinService CoinService = new BitcoinService(useTestnet: true);
+ {
+ // Read 'UseTestnet' flag from App.config instead of hardcoding
+ private static readonly bool UseTestnet = bool.Parse(ConfigurationManager.AppSettings["UseTestnet"]);
+
+ // Inject useTestnet setting into the BitcoinService
+ private static readonly ICoinService CoinService = new BitcoinService(useTestnet: UseTestnet);
private static void Main()
{