View Single Post
  #9  
Old 14.10.2019, 07:34
mgpai mgpai is offline
Script Master
 
Join Date: Sep 2013
Posts: 625
Default

It is better to use it like this, just in case the filepaths also contain folder which match the host name. Can choose to keep/remove '.reverse()' depending on your preference of sort order.

Code:
var files = getPath(folder).getChildren().filter(function(filePath) {
    return filePath.isFile() && filePath.toString().indexOf(host) > -1;
}).reverse();
Reply With Quote