fix undefined referances.