Commit c484da61 authored by 刘文胜's avatar 刘文胜

1111

parent de322748
......@@ -333,14 +333,14 @@ router.get('/sharev2.js', function(req, res, next) {
//type为index时的,默认link
link = config.service + '/app/forum/' + ent_code + '/mediashequn'
request.get({url:config.rest_api+'/v1.0/internal/forum/config/enter/byentcode?entCode='+ent_code,body:{},json:true}, function (e, r, result) {
if(result.data){
if(result && result.data){
link = result.data;
}
cont();
});
},function(cont){
request.get({url:config.rest_api+'/v1.0/internal/forum/config/share/byentcode?entCode='+ent_code,body:{},json:true}, function (e, r, result) {
if(result.data){
if(result && result.data){
try{
var obj = JSON.parse(result.data);
title = obj.shareTitle || '';
......@@ -381,7 +381,7 @@ router.get('/sharev2.js', function(req, res, next) {
res.json(_.assign({result:false},returnCode.WRONG_PARAM));
}else if(type === 'notice'){
Notice.findOne({_id:id},function(err,result){
if (err) {
if (err || !result) {
console.error(err);
res.json(_.assign({result:false},returnCode.BUSY));
}
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment