Changed script of buy flow