提交 2a758a03 编写于 作者: fxy060608's avatar fxy060608

fix(uts): mutiple class instance

上级 515f9b20
......@@ -173,7 +173,9 @@ function initUTSProxyClass(options) {
let constructorParams = [];
let staticMethods = {};
let staticProps = [];
let isProxyInterface = false;
if (isProxyInterfaceOptions(options)) {
isProxyInterface = true;
instanceId = options.instanceId;
}
else {
......@@ -194,8 +196,8 @@ function initUTSProxyClass(options) {
}
const target = {};
// 初始化实例 ID
if (isUndefined(instanceId)) {
// 未指定instanceId
if (!isProxyInterface) {
// 初始化未指定时,每次都要创建instanceId
instanceId = initProxyFunction(false, extend({ name: 'constructor', params: constructorParams }, baseOptions), 0).apply(null, params);
}
if (!instanceId) {
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册