refactor favorites