The imperial court sent an imperial envoy to inspect the border. The imperial envoy accepted bribes from local prominent families and falsely accused Shen Yan of abusing people's power. Shen Yan argued hard and produced evidence of Beidi's robbery to clear his grievances.