diff --git a/src/ConfigurationProcessor.Core/Implementation/StringArgumentValue.cs b/src/ConfigurationProcessor.Core/Implementation/StringArgumentValue.cs index c0331cd..d34be44 100644 --- a/src/ConfigurationProcessor.Core/Implementation/StringArgumentValue.cs +++ b/src/ConfigurationProcessor.Core/Implementation/StringArgumentValue.cs @@ -35,6 +35,11 @@ public StringArgumentValue(IConfigurationSection section, string providedValue) { var argumentValue = Environment.ExpandEnvironmentVariables(providedValue); + if (toType == typeof(string)) + { + return providedValue; + } + var toTypeInfo = toType.GetTypeInfo(); if (toTypeInfo.IsGenericType && toType.GetGenericTypeDefinition() == typeof(Nullable<>)) {