fix for incomplete caseid bug