added db support for follow links, still very buggy