Only try matching regex to the string if the string actually exists
Conforming to code style
Updated pod spec