提交 b8963227 编写于 作者: Q qiang

chore: build runtime

上级 46a39043
......@@ -192,7 +192,7 @@ function queue (hooks, data) {
}
if (res === false) {
return {
then () {}
then () { }
}
}
}
......@@ -272,10 +272,14 @@ const promiseInterceptor = {
if (!isPromise(res)) {
return res
}
return res.then(res => {
return res[1]
}).catch(res => {
return res[0]
return new Promise((resolve, reject) => {
res.then(res => {
if (res[0]) {
reject(res[0]);
} else {
resolve(res[1]);
}
});
})
}
};
......
......@@ -192,7 +192,7 @@ function queue (hooks, data) {
}
if (res === false) {
return {
then () {}
then () { }
}
}
}
......@@ -272,10 +272,14 @@ const promiseInterceptor = {
if (!isPromise(res)) {
return res
}
return res.then(res => {
return res[1]
}).catch(res => {
return res[0]
return new Promise((resolve, reject) => {
res.then(res => {
if (res[0]) {
reject(res[0]);
} else {
resolve(res[1]);
}
});
})
}
};
......
......@@ -192,7 +192,7 @@ function queue (hooks, data) {
}
if (res === false) {
return {
then () {}
then () { }
}
}
}
......@@ -272,10 +272,14 @@ const promiseInterceptor = {
if (!isPromise(res)) {
return res
}
return res.then(res => {
return res[1]
}).catch(res => {
return res[0]
return new Promise((resolve, reject) => {
res.then(res => {
if (res[0]) {
reject(res[0]);
} else {
resolve(res[1]);
}
});
})
}
};
......
......@@ -192,7 +192,7 @@ function queue (hooks, data) {
}
if (res === false) {
return {
then () {}
then () { }
}
}
}
......@@ -272,10 +272,14 @@ const promiseInterceptor = {
if (!isPromise(res)) {
return res
}
return res.then(res => {
return res[1]
}).catch(res => {
return res[0]
return new Promise((resolve, reject) => {
res.then(res => {
if (res[0]) {
reject(res[0]);
} else {
resolve(res[1]);
}
});
})
}
};
......
......@@ -192,7 +192,7 @@ function queue (hooks, data) {
}
if (res === false) {
return {
then () {}
then () { }
}
}
}
......@@ -272,10 +272,14 @@ const promiseInterceptor = {
if (!isPromise(res)) {
return res
}
return res.then(res => {
return res[1]
}).catch(res => {
return res[0]
return new Promise((resolve, reject) => {
res.then(res => {
if (res[0]) {
reject(res[0]);
} else {
resolve(res[1]);
}
});
})
}
};
......
......@@ -192,7 +192,7 @@ function queue (hooks, data) {
}
if (res === false) {
return {
then () {}
then () { }
}
}
}
......@@ -272,10 +272,14 @@ const promiseInterceptor = {
if (!isPromise(res)) {
return res
}
return res.then(res => {
return res[1]
}).catch(res => {
return res[0]
return new Promise((resolve, reject) => {
res.then(res => {
if (res[0]) {
reject(res[0]);
} else {
resolve(res[1]);
}
});
})
}
};
......
......@@ -192,7 +192,7 @@ function queue (hooks, data) {
}
if (res === false) {
return {
then () {}
then () { }
}
}
}
......@@ -272,10 +272,14 @@ const promiseInterceptor = {
if (!isPromise(res)) {
return res
}
return res.then(res => {
return res[1]
}).catch(res => {
return res[0]
return new Promise((resolve, reject) => {
res.then(res => {
if (res[0]) {
reject(res[0]);
} else {
resolve(res[1]);
}
});
})
}
};
......
......@@ -192,7 +192,7 @@ function queue (hooks, data) {
}
if (res === false) {
return {
then () {}
then () { }
}
}
}
......@@ -272,10 +272,14 @@ const promiseInterceptor = {
if (!isPromise(res)) {
return res
}
return res.then(res => {
return res[1]
}).catch(res => {
return res[0]
return new Promise((resolve, reject) => {
res.then(res => {
if (res[0]) {
reject(res[0]);
} else {
resolve(res[1]);
}
});
})
}
};
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册