Properly quit browser