added cases form back into code