Disable executing handler method in spawned thread