Adding null check