setting things up for 'quit' functionality