Turret wont stop shooting once target is dead.

So I’ve created this gun turret and I finally got it to target a basic enemy instead of me. Now the issue is that when it destroys an enemy it keeps shooting. what am I doing wrong?

1.make sure your enemy in range is updated properly.
2.make sure that your enemy upon death actually gets destroyed.
(no reference to it, I think this should be fixed already but still play safe if you save a reference somewhere.)
3.when you check for enemy in range, not just if they exist or not, also check for if they are dead or not.