MtApi5: fixed problem of null string in command's parameters

This commit is contained in:
Viacheslav Demydiuk
2024-02-24 21:33:35 +02:00
parent 4d0b0ce513
commit 64c10415a7
3 changed files with 160 additions and 143 deletions
+16 -1
View File
@@ -1,4 +1,6 @@
namespace MtApi5
using MtApi5.MtProtocol;
namespace MtApi5
{
public class MqlTick
{
@@ -15,6 +17,19 @@
{
}
internal MqlTick(MtTick? tick)
{
if (tick != null)
{
MtTime = tick.Time;
bid = tick.Bid;
ask = tick.Ask;
last = tick.Last;
volume = tick.Volume;
volume_real = tick.VolumeReal;
}
}
public long MtTime { get; set; } // Time of the last prices update
public double bid { get; set; } // Current Bid price