add optionMap

This helps type inference; otherwise flatMap needed a type added on.