mirror of
				https://github.com/earthjasonlin/zzz-signal-search-export.git
				synced 2025-11-04 22:20:10 +08:00 
			
		
		
		
	@@ -138,15 +138,8 @@ const readLog = async () => {
 | 
				
			|||||||
    }
 | 
					    }
 | 
				
			||||||
    const promises = logPaths.map(async logpath => {
 | 
					    const promises = logPaths.map(async logpath => {
 | 
				
			||||||
      const logText = await fs.readFile(logpath, 'utf8')
 | 
					      const logText = await fs.readFile(logpath, 'utf8')
 | 
				
			||||||
      const gamePathMch = logText.match(/\w:\/.*?\/StarRail_Data\//i)
 | 
					      const url = logText.match(/https:\/\/.*?\/info/g)
 | 
				
			||||||
      if (gamePathMch) {
 | 
					      return getLatestUrl(url)
 | 
				
			||||||
        const [cacheText, cacheFile] = await getCacheText(gamePathMch[0])
 | 
					 | 
				
			||||||
        const urlMch = cacheText.match(/https[^?]+?\?[^?]+?&auth_appid=webview_gacha&.+?authkey=.+?&game_biz=hkrpg_.+?&plat_type=pc/g)
 | 
					 | 
				
			||||||
        if (urlMch) {
 | 
					 | 
				
			||||||
          cacheFolder = cacheFile.replace(/Cache_Data[/\\]data_2$/, '')
 | 
					 | 
				
			||||||
          return getLatestUrl(urlMch)
 | 
					 | 
				
			||||||
        }
 | 
					 | 
				
			||||||
      }
 | 
					 | 
				
			||||||
    })
 | 
					    })
 | 
				
			||||||
    const result = await Promise.all(promises)
 | 
					    const result = await Promise.all(promises)
 | 
				
			||||||
    for (let url of result) {
 | 
					    for (let url of result) {
 | 
				
			||||||
 
 | 
				
			|||||||
		Reference in New Issue
	
	Block a user