Don't overwrite status to email opened if the user has already clicked the link or submitted data. Fixes #529

pull/535/merge
Jordan Wright 2017-02-23 23:23:05 -06:00
parent 5c20035e71
commit d67dcc889a
1 changed files with 1 additions and 1 deletions

View File

@ -145,7 +145,7 @@ func PhishTracker(w http.ResponseWriter, r *http.Request) {
c.AddEvent(models.Event{Email: rs.Email, Message: models.EVENT_OPENED, Details: string(rj)})
// Don't update the status if the user already clicked the link
// or submitted data to the campaign
if rs.Status == models.STATUS_SUCCESS {
if rs.Status == models.EVENT_CLICKED || rs.Status == models.EVENT_DATA_SUBMIT {
http.ServeFile(w, r, "static/images/pixel.png")
return
}