fixed multiple files handling