Rewrite code a bit more.