guard 'if' in case no file name