fix stream
This commit is contained in:
@@ -1,8 +1,5 @@
|
|||||||
namespace s8n_runtime;
|
namespace s8n_runtime;
|
||||||
|
|
||||||
using System.Text.Json;
|
|
||||||
using System.Text.Json.Serialization;
|
|
||||||
|
|
||||||
public class WorkflowRuntimeRunner
|
public class WorkflowRuntimeRunner
|
||||||
{
|
{
|
||||||
private static readonly JsonSerializerOptions serializerOptions = new(JsonSerializerDefaults.Web)
|
private static readonly JsonSerializerOptions serializerOptions = new(JsonSerializerDefaults.Web)
|
||||||
@@ -43,7 +40,8 @@ public class WorkflowRuntimeRunner
|
|||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
runtime = JsonSerializer.Deserialize<TWorkflow>(File.OpenRead(filePath), serializerOptions)!;
|
using var stream = File.OpenRead(filePath);
|
||||||
|
runtime = JsonSerializer.Deserialize<TWorkflow>(stream, serializerOptions)!;
|
||||||
}
|
}
|
||||||
runtime.Prepare();
|
runtime.Prepare();
|
||||||
|
|
||||||
|
|||||||
@@ -11,7 +11,7 @@
|
|||||||
<!-- Package properties below -->
|
<!-- Package properties below -->
|
||||||
<IsPackable>true</IsPackable>
|
<IsPackable>true</IsPackable>
|
||||||
<PackageId>Sharp8N.Runtime</PackageId>
|
<PackageId>Sharp8N.Runtime</PackageId>
|
||||||
<Version>1.0.11</Version>
|
<Version>1.0.12</Version>
|
||||||
<Authors>Vitalick S</Authors>
|
<Authors>Vitalick S</Authors>
|
||||||
<Company>Sharp8N</Company>
|
<Company>Sharp8N</Company>
|
||||||
<Description>Sharp8N runtime library, that allows run s8n workflows</Description>
|
<Description>Sharp8N runtime library, that allows run s8n workflows</Description>
|
||||||
|
|||||||
Reference in New Issue
Block a user