mirror of
https://github.com/GSA/notifications-admin.git
synced 2026-04-12 05:10:45 -04:00
We were previously persisting the logo for the email branding and deleting the temp files that get created before trying to update the database with the new email branding. This meant that if there was an error when saving (e.g. the domain used was a duplicate) the final logo was already in S3 and trying to go 'back' in the browser would give an error since the temp files needed to display the create branding page had already been deleted. This changes the order we do things in, so that we try persisting the email branding to the database first.