app/models/import.rb
#counts number of files in the directory 
counts number of files in the directory
counts number of files in the directory
def dir_file_count
    directory = APP_CONFIG['import_maps_sftp_path']
    count =  Dir[File.join(directory, '**')].count { |file| File.file?(file) }
    return count
  end
def dir_file_count directory = APP_CONFIG [ 'import_maps_sftp_path' ] count = Dir [ File . join ( directory , '**' ) ] . count { | file | File . file? ( file ) } return count end
counts number of files in the directory
counts number of files in the directory