Quick bugfix where I should have checked for undefined.