Indicator Error on first load

 

Hello guys. Recently I wrote an indicator showing high and low values of previous day. But sometimes it draws wrong levels of last 1-2 days on first load. After I re-load indicator on same chart it fixes the drawed levels.
Screenshots attached. I can send my source code if there is anyone interested in fixing this issue.

Files:
EURCADH1.png  95 kb
EURCADH1_2.png  98 kb
Reason: