syncing router and db (closes #11 and #18)