Add unique index to memberships to avoid duplicate records
The memberships table does not currently have any constraints/indexes to prevent duplicate entries, e.g. it is theoretically possible to have a membership record where a user is a member and admin simultaneously, or two admin/member records;
Before this was applied, we had a small amount of records keeping us from applying the index. The first part of the migration therefore deletes those offending records; the second part then creates the index.