Small fix to prevent null reference exception