Rewrite for v2.1.x series