Authored by ccbikai(👎🏻🍜)

Merge remote-tracking branch 'origin/feature/dailyRecord' into hotfix/online-err

... ... @@ -103,7 +103,7 @@ const getResources = (params, options) => {
let list = {};
let productSkns = [];
if (result.code !== 200) {
if (result && result.code !== 200) {
return data;
}
... ...
... ... @@ -233,7 +233,7 @@ const order = (params) => {
code: 200
}).then(result => {
if (result.data) {
if (result && result.data) {
Object.assign(finalResult, {cancelReason: result.data});
}
... ...
... ... @@ -18,7 +18,7 @@ exports.page = (req, res, next) => {
userApi.profile(req.user.uid)
.then(userinfo => {
userinfo = userinfo.data;
userinfo = userinfo.data || {};
res.render('chat/index', {
module: 'service',
... ... @@ -30,7 +30,7 @@ exports.page = (req, res, next) => {
imSocket: global.yoho.config.domains.imSocket,
userData: {
encrypteduid: crypto.encryption(null, uid + ''),
avatar: helpers.image(userinfo.head_ico, 100, 100),
avatar: userinfo.head_ico ? helpers.image(userinfo.head_ico, 100, 100) : '',
uname: userinfo.profile_name
}
});
... ...