Use self.type() like you did in link_func?

Actually, is it possible to get rid of this method and just use link_func?