dwyl / github-backup

:octocat: :back: 🆙 Backup your GitHub Issues so you can still work when (they/you are) offline.
https://github-backup.herokuapp.com
GNU General Public License v2.0
32 stars 3 forks source link

Return Phoenix connection for any uncaught webhooks #82

Closed SimonLab closed 6 years ago

SimonLab commented 6 years ago

linked to https://github.com/dwyl/github-backup/issues/65#issuecomment-372579790

If an event is not matched the server should still return a response. Instead of just returning nil https://github.com/dwyl/github-backup/blob/7b6d7332f72e0b3ebe793e4bb0f4e7ea5894c829/lib/app_web/controllers/event_type.ex#L16 We want to return a 404 reply

conn
|> put_status(404)
|> json(%{ok: "event unknown"})
nelsonic commented 6 years ago

@SimonLab thanks for addressing this. 🎉