diff --git a/DTLib.Dtsod/DtsodV23.cs b/DTLib.Dtsod/DtsodV23.cs index a4853ec..646d647 100644 --- a/DTLib.Dtsod/DtsodV23.cs +++ b/DTLib.Dtsod/DtsodV23.cs @@ -28,7 +28,7 @@ public class DtsodV23 : DtsodDict, IDtsod while (i < text.Length) { string name = ReadName(); - if (name == "") goto end; + if (name.IsNullOrEmpty()) goto end; dynamic value = ReadValue(out bool _); if (partOfDollarList) { @@ -250,7 +250,6 @@ public class DtsodV23 : DtsodDict, IDtsod case '[': value=ReadList(); goto case ';'; - break; case ']': endOfList = true; break; diff --git a/DTLib/Filesystem/OldFilework.cs b/DTLib/Filesystem/OldFilework.cs index c771425..489ddb4 100644 --- a/DTLib/Filesystem/OldFilework.cs +++ b/DTLib/Filesystem/OldFilework.cs @@ -45,7 +45,7 @@ public static class OldFilework value += st[i]; } reader.Close(); - //if (value == "") throw new System.Exception($"ReadFromConfig({configfile}, {key}) error: key not found"); + //if (value.NullOrEmpty()) throw new System.Exception($"ReadFromConfig({configfile}, {key}) error: key not found"); return value; } }