|
|
@@ -7,6 +7,7 @@ import com.usoftchina.saas.exception.BizException;
|
|
|
import com.usoftchina.saas.sms.config.SmsConfig;
|
|
|
import com.usoftchina.saas.sms.dto.SmsDTO;
|
|
|
import com.usoftchina.saas.sms.service.SmsService;
|
|
|
+import com.usoftchina.saas.utils.ObjectUtils;
|
|
|
import org.springframework.beans.factory.annotation.Autowired;
|
|
|
import org.springframework.boot.context.properties.EnableConfigurationProperties;
|
|
|
import org.springframework.web.bind.annotation.*;
|
|
|
@@ -28,7 +29,7 @@ public class SmsController {
|
|
|
} catch (ClientException e) {
|
|
|
return Result.error(new BizException(Integer.parseInt(e.getErrCode()), e.getMessage()));
|
|
|
}
|
|
|
- return Result.success(sendSmsResponse.getMessage());
|
|
|
+ return Result.success(ObjectUtils.isEmpty(sendSmsResponse) ? null : sendSmsResponse.getMessage());
|
|
|
}
|
|
|
|
|
|
}
|