Improve code
Improve exception record.