If your code plots multiple times the arrow, it is because your conditions are still fulfilled!
Without reading your code, there are multiple ways to handle that, but first try by checking if your conditions wasn’t true before the first placement of the arrow: