reimplement check context