It wasn't like that. Like Barbara Windsor, Pam quit but hoped not to be killed off sos he could return one day.
But they decided to give Pat the best send off was to kill her off (and tbf it was amazing TV at the time) as letting her leave was to similar to Babs exit only a year or so before.