added quit command functionality