Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.
}).then(result => {
Taro.hideLoading();
if (result.status === 'error') {
showToast(result.message);
}
console.log('获取最新节点', result);
this.props.dispatch({
type: LATEST_TOPIC_LIST,
data: result.data
});
}).catch(error => {
showToast(error.message);
}).then(result => {
Taro.hideLoading();
if (result.status === 'error') {
showToast(result.message);
}
console.log('获取最热节点', result);
this.props.dispatch({
type: HOT_TOPIC_DATA,
data: result.data
});
}).catch(error => {
showToast(error.message);
}).then(result => {
Taro.hideLoading();
if (result.status === 'error') {
showToast(result.message);
}
console.log('获取帖子详情', result);
this.props.dispatch({
type: TOPIC_DETAIL_DATA,
data: result.data
});
}).catch(error => {
showToast(error.message);