Fix quota logic.