SES-1736 : Simplify logic in parseDirective