removes code duplication, moves code to AutoFragment, name will be changed. also fixes bug with link parsing and fixes dependency versions