moving attach avatar model logic into module
test refactor later