Upd Implementation to work in context