Simpler version of previous commit.