added some case handling for parse