Fix & update

Extension array method - GetRow
Fix use path for crossplatform
pull/1/head
unknown 3 years ago
parent 90359e5d60
commit 516407064b

@ -27,7 +27,7 @@ Based on System.Data.SQLite.Core</Description>
</ItemGroup> </ItemGroup>
<ItemGroup> <ItemGroup>
<PackageReference Include="System.Data.SQLite.Core" Version="1.0.114.3" /> <PackageReference Include="System.Data.SQLite.Core" Version="1.0.115" />
</ItemGroup> </ItemGroup>
<ItemGroup> <ItemGroup>

@ -1,4 +1,5 @@
using System; using System;
using System.Collections.Generic;
using System.Linq; using System.Linq;
namespace ZeroLevel namespace ZeroLevel
@ -73,6 +74,14 @@ namespace ZeroLevel
|| candidate.Length > array.Length; || candidate.Length > array.Length;
} }
public static IEnumerable<T> GetRow<T>(T[,] array, int row)
{
for (int i = 0; i < array.GetLength(1); i++)
{
yield return array[row, i];
}
}
public static bool Equals(byte[] first, byte[] second) public static bool Equals(byte[] first, byte[] second)
{ {
if (null == first && null == second) if (null == first && null == second)

@ -161,7 +161,7 @@ namespace ZeroLevel.Services.FileSystem
} }
foreach (var file in files) foreach (var file in files)
{ {
var filepath = Path.Combine(tmp, file.FullName.Replace(sourceFolder, string.Empty).TrimStart('\\')); var filepath = Path.Combine(tmp, file.FullName.Replace(sourceFolder, string.Empty).TrimStart('\\', '/'));
var filedir = Path.GetDirectoryName(filepath); var filedir = Path.GetDirectoryName(filepath);
if (false == Directory.Exists(filedir)) if (false == Directory.Exists(filedir))
{ {

@ -1,6 +1,6 @@
namespace ZeroLevel.Services.Serialization namespace ZeroLevel.Services.Serialization
{ {
internal static class JsonEscaper public static class JsonEscaper
{ {
/// <summary> /// <summary>
/// Checking if needed escaping string for use as json value /// Checking if needed escaping string for use as json value

Loading…
Cancel
Save

Powered by TurnKey Linux.