fixed issue when no number of files was given