mirror of
https://github.com/alibaba/lowcode-engine.git
synced 2025-12-12 11:20:11 +00:00
fix: remove function bind
If the returned function is bound to a context, there is no way to call it with `call` and `apply`.
This commit is contained in:
parent
ce7e766b86
commit
fc947d2feb
@ -264,8 +264,7 @@ function parseExpression(a: any, b?: any, c = false) {
|
||||
if (!thisRequired) {
|
||||
code = `with($scope){${code}}`;
|
||||
}
|
||||
const result = new Function('$scope', code)(self);
|
||||
return typeof result === "function" ? result.bind(self): result;
|
||||
return new Function('$scope', code)(self);
|
||||
} catch (err) {
|
||||
logger.error(`${logScope || ''} parseExpression.error`, err, str, self?.__self ?? self);
|
||||
return undefined;
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user