fixing the EB/EE inversion