Added null check to repository pull.