Change back to assert, and other small changes.