Fix minor bug in option detection
Merge pull request #2269 from ghost1227/issue/1836

Resubmitting with a minor tweak... nothing really new yet, just cleanup