improvements are rebased on staging branch