Added checkLink functionality