Fixes to avoid close browser