Skip to content

Commit 8f251ae

Browse files
committed
Another bug in position flipping fixed.
Changes to be committed: modified: Base/OANDA-PlaceOrder
1 parent b238337 commit 8f251ae

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

Base/OANDA-PlaceOrder

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -352,7 +352,7 @@ def main():
352352
else:
353353
step=1
354354

355-
if relay.Order['Action']=='buy':
355+
if relay.Order['Action']=='buy' and ((amount>0 and units>0) or (amount<0 and units<0)):
356356
amount=LowestLotSize(relay,relay.Order['Asset'],amount,step)
357357
elif 'Ticket' in relay.Order:
358358
amount=GetTicket(relay,relay.Order['Asset'],relay.Order['Ticket'],amount)

0 commit comments

Comments
 (0)