first go at saving IDs correctly