fix undefined things