|
@@ -11,6 +11,7 @@ import (
|
|
|
"hongze/hongze_yb/services/community"
|
|
|
"hongze/hongze_yb/services/user"
|
|
|
"hongze/hongze_yb/utils"
|
|
|
+ "io/ioutil"
|
|
|
"os"
|
|
|
"path"
|
|
|
"time"
|
|
@@ -212,7 +213,7 @@ func QuestionUploadAudio(c *gin.Context) {
|
|
|
return
|
|
|
}
|
|
|
// 获取音频文件时长
|
|
|
- fByte, err := os.ReadFile(fpath)
|
|
|
+ fByte, err := ioutil.ReadFile(fpath)
|
|
|
if err != nil {
|
|
|
response.FailMsg("读取本地文件失败", "QuestionUploadAudio 读取本地文件失败", c)
|
|
|
return
|