Add undefined check for expandFiles

if `options` is undefined in `expandFiles` function, this method throws exceptions like `Cannot read property 'cwd' of undefined`.
So I add a check options is `undefined` or not.

If you accept this fix, please merge.