Try this:
fun same_string(str, lst) =
case lst of
[] => NONE
|x::xs => case same_string(str, xs) of
NONE => if str = x
then SOME(xs)
else NONE
|SOME xs' => SOME (x :: xs')