Exit Strategy not working properly

I have a EMA based strategy to enter the position which is working fine. But as and when trade gets executed, i want Exit to be 10 point higher on long side and 10 points lower on short side. But the trade gets exited automatically in the next minute itself.

@vikram.bajaj Please help why i am facing this error. do you see any flaws in the code below.