Revert most of the previous commit because it was all irrelevant to the problem