docs: documented bind Enviroment

This commit is contained in:
Gabriel Grubba
2022-11-22 14:49:47 -03:00
parent cf30fc3c78
commit f5be18fb01

View File

@@ -200,6 +200,9 @@ const bindEnvironmentFibers = (func, onException, _this) => {
};
};
// This function has two reasons:
// 1. Return the function to be executed on the MeteorJS context, having it assinged in the async localstorage.
// 2. Better error handling, the error message will be more clear.
const bindEnvironmentAsync = (func, onException, _this) => {
var dynamics = Meteor._getValueFromAslStore("_meteor_dynamics");
var boundValues = Array.isArray(dynamics) ? dynamics.slice() : [];