Change this loop and conditional to be:

`if(e.getHeader('Application') === appName`

no need for a loop here.