Update thin code to work with browser wrapper