removed deprecated context function