Doing Cmd_. still plays my Pdefs

I have a startup file ( parts of it below). Everytime I press Cmd-. the Pdefs starts playing again. Not sure why and how to get around this.

~cleanup = {
	s.newBusAllocators;
	ServerBoot.removeAll;
	ServerTree.removeAll;
	ServerQuit.removeAll;
	CmdPeriod.removeAll;
};


  ServerTree.add(~makeBusses);
  ServerTree.run;
ServerQuit.add(~cleanup);

~cleanup.();

That’s not normal behavior, so you must have added something to either CmdPeriod or ServerTree that is restarting them. (Or, another possibility is that you might have installed an extension somewhere that is restarting them.)

hjh

Yes, I thought so. I removed CmdPeriod.removeAll and added another line below. And that seems to work.


~cleanup = {
	s.newBusAllocators;
	ServerBoot.removeAll;
	ServerTree.removeAll;
	ServerQuit.removeAll;
	/*CmdPeriod.removeAll;*/
};


  ServerTree.add(~makeBusses);
  ServerTree.run;
  ServerQuit.add(~cleanup);
  CmdPeriod.add({Pbindef.clear});

~cleanup.();