added exit function, whoops!

Thanks for the pickup @gmarnin