Added a null check here to make it more clear.