keyErrorMessage() is not a function in collection2


#1

var cfc = Fund.simpleSchema().namedContext('createFund'); var errorKeys = cfc.invalidKeys(); errorKeys = _.map(errorKeys,function(errorKey){ return _.extend({message:cfc.keyErrorMessage(errorKey.name)},errKey) });
I got keyErrorMessage is not a function, but in simple-schema docs, using this method to get error messages. so I have no idea that how to get error messages. How can I do this? Please help.