fixed linking bug