From afd87bd37619e5cc6606271d76e10d87b3574a5d Mon Sep 17 00:00:00 2001 From: Aptivi Date: Wed, 9 Oct 2024 18:56:58 +0300 Subject: [PATCH] imp - Trim keys and values for prop arguments --- We've improved support for whitespaces around properties. --- Type: imp Breaking: False Doc Required: False Backport Required: False Part: 1/1 --- VisualCard/Parsers/Arguments/ArgumentInfo.cs | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/VisualCard/Parsers/Arguments/ArgumentInfo.cs b/VisualCard/Parsers/Arguments/ArgumentInfo.cs index c384327..8f64a79 100644 --- a/VisualCard/Parsers/Arguments/ArgumentInfo.cs +++ b/VisualCard/Parsers/Arguments/ArgumentInfo.cs @@ -142,14 +142,14 @@ internal ArgumentInfo(string kvp) if (kvp.Contains(VcardConstants._argumentValueDelimiter)) { string keyStr = kvp.Substring(0, kvp.IndexOf(VcardConstants._argumentValueDelimiter)); - string valueStr = kvp.RemovePrefix($"{keyStr}{VcardConstants._argumentValueDelimiter}"); - var info = new ArgumentInfo(keyStr, valueStr); + string valueStr = kvp.RemovePrefix($"{keyStr}{VcardConstants._argumentValueDelimiter}").Trim(); + var info = new ArgumentInfo(keyStr.Trim(), valueStr); key = info.key; values = info.values; } else { - var info = new ArgumentInfo("", kvp); + var info = new ArgumentInfo("", kvp.Trim()); key = ""; values = info.values; }