4.0.0 rewrite against 3.0.8