fix node npm detection (#1163)

This commit is contained in:
ekko
2026-05-30 20:19:01 +08:00
committed by GitHub
parent dcbf601e35
commit fc35c74eb3
18 changed files with 406 additions and 53 deletions
@@ -77,6 +77,9 @@ async function loadRecommendations() {
const response = await fetch(recommendationsPath.value)
if (!response.ok) throw new Error(`HTTP ${response.status}`)
const text = await response.text()
if (/^\s*<!doctype html/i.test(text) || /^\s*<html[\s>]/i.test(text)) {
throw new Error('Skill recommendations file was not found')
}
if (requestSeq === recommendationsRequestSeq) {
recommendations.value = text
}