handle no file case