クリティカル使わないから隠したいんだけど

UnitParameter.critical.isParameterDisplayable= function() {
return false;
}

これでやったらエラーになったんだけど何か間違ってる?