I figured it out. In my game, if player leaves a certain area, player has to die. And when I change the scene, the "area_exited" signal is executed from that
Area2D and it restarts the scene before it can change to next level.
So I simply added this to level script:
var finished : bool = false
And this to the
if body == level.player and !level.finished:
Anyway still thanks to IceExplosive for trying to help!