只要我包含以下代码就提示【你的小游戏代码中含AppSecret,存在安全风险】审核不通过,屏蔽就可以,但是以下代码没有appsecret啊?
public async checkGameLiveInfo(): Promise<GameLiveObj> {
return new Promise((resolve) => {
let feedIds = new Set<string>()
//首先登录
window["wx"]?.login({
success: async (logonRes) => {
//获取直播信息
if (window["wx"] && window["wx"]?.getUserRecentGameLiveInfo) {
//获取最近直播列表
window["wx"]?.getUserRecentGameLiveInfo({
success: (infoRes) => {
let arr: Array<string> = infoRes.feedIdList
for (let id of arr) {
feedIds.add(id)
}
//根据直播id获取直播信息
if (window["wx"] && window["wx"]?.getUserGameLiveDetails) {
window["wx"]?.getUserGameLiveDetails({
feedIdList: Array.from(feedIds.values()),
success: async (detalsRes) => {
console.log(`传输参数code:${logonRes.code} `)
console.log(`传输参数encryptedData:${detalsRes.encryptedData} `)
console.log(`传输参数iv:${detalsRes.iv} `)
let data: GameLiveObj = await this.callCloudFunc("dataCrypt", {
code: logonRes.code,
encryptedData: detalsRes.encryptedData,
iv: detalsRes.iv,
})
console.log("解密数据", data)
resolve(data)
},
fail: () => {
resolve(null)
其他前端代码也找下