clean up digest()