adding fixes found in local testing