send email when download completed, fix: getting wrong sourcedirid