Remove a bunch of workaround code