Skip to content

Commit

Permalink
Remove Dependancy
Browse files Browse the repository at this point in the history
  • Loading branch information
LoneWandererProductions committed Dec 4, 2023
1 parent 549df06 commit c251c0d
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 4 deletions.
5 changes: 2 additions & 3 deletions Serializer/Serialize.cs
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,6 @@
using System.Linq;
using System.Xml;
using System.Xml.Serialization;
using ExtendedSystemObjects;
using FileHandler;

namespace Serializer
Expand Down Expand Up @@ -138,7 +137,7 @@ public static void SaveDctObjectToXml<TKey, TValue>(Dictionary<TKey, TValue> dct
FileHandleCreate.CreateFolder(folder);

//check if file is empty, if empty return
if (dct.IsNullOrEmpty())
if (dct == null || dct.Count == 0)
{
throw new ArgumentException(SerialResources.ErrorSerializerEmpty);
}
Expand Down Expand Up @@ -183,7 +182,7 @@ private static string Handle<T>(this T obj)
private static void SerializeDictionary(Dictionary<string, string> dct, string path)
{
//check if file is empty, if empty return
if (dct.IsNullOrEmpty())
if (dct == null || dct.Count == 0)
{
throw new ArgumentException(SerialResources.ErrorSerializerEmpty);
}
Expand Down
1 change: 0 additions & 1 deletion Serializer/Serializer.csproj
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,6 @@
</PropertyGroup>

<ItemGroup>
<ProjectReference Include="..\ExtendedSystemObjects\ExtendedSystemObjects.csproj" />
<ProjectReference Include="..\FileHandler\FileHandler.csproj" />
</ItemGroup>

Expand Down

0 comments on commit c251c0d

Please sign in to comment.