Fix wrong-type-argument error when opening id link