small change

gives time to finish saving logs
debug
more consistency with stream handling

aas_getfiles_bystream is more robust than aas_getimages_bystream
increase readability