文件
huaqiapp/uni.promisify.adaptor.js
linda d14fc79e05 chore: 初始化 huaqiapp 仓库
- 前端:uni-app 基础工程(App.vue / pages / static / manifest.json 等)
- 后端:从线上服务器 huaqiapp.gzyakj.com.cn 拉取的 FastAdmin(ThinkPHP) 源码,存放于 server/
- .gitignore 排除依赖、运行时、上传目录、打包产物及含敏感信息的 AGENTS.md
2026-11-02 22:58:56 +08:00

13 行
373 B
JavaScript

uni.addInterceptor({
returnValue (res) {
if (!(!!res && (typeof res === "object" || typeof res === "function") && typeof res.then === "function")) {
return res;
}
return new Promise((resolve, reject) => {
res.then((res) => {
if (!res) return resolve(res)
return res[0] ? reject(res[0]) : resolve(res[1])
});
});
},
});