moved the browser.close call to single location that makes the most sense.  switched from shell to system.

Firefox is having problems shutting down all the way on OSX 10.8