Code rewritten.