Logical error for link image null check