Meds block the communication or influence but do not remove the spirit attachment.
Since the priest made no effort to get rid of the spiritual attachment, it’s a good thing she had meds to fall back on.