refactor into nice fns & move calls into success