debug(sync): diag inclut la chaîne mine=true (id+titre) pour comparaison

This commit is contained in:
2026-09-27 09:01:06 -04:00
parent fdb5a48023
commit a3d29fe3cd
2 changed files with 18 additions and 1 deletions
+6 -1
View File
@@ -108,7 +108,7 @@ import {
fetchGoogleLiked, fetchTwitchProfile, fetchTwitchFollows, hasGoogleWriteScope,
fetchGoogleWatchLater, pushGoogleWatchLater, fetchInnerTubeHistory,
fetchInnerTubeWatchLaterViaLib, pushInnerTubeWatchLater, fetchGoogleWatchLaterId,
fetchAccountChannels, diagnoseInnertube,
fetchAccountChannels, diagnoseInnertube, fetchMineChannel,
} from './oauth.mjs';
import { getSearchMode, getYtDlpBin, hasCookiesFile, metricsSnapshot } from './providers/youtube-common.mjs';
import { ytScrapeCacheStats } from './providers/youtube.mjs';
@@ -590,6 +590,11 @@ r.get('/oauth/google/diag', authMiddlewareCookieAware, oauthLimiter, async (req,
try {
const conn = await freshOAuthToken(req.user.id, 'google');
const dataApi = {};
try {
dataApi.mineChannel = await fetchMineChannel(conn.accessToken);
} catch (e) {
dataApi.mineChannel = { error: String(e?.message || '').slice(0, 80) };
}
try {
await fetchGoogleWatchLaterId(conn.accessToken);
dataApi.watchLaterId = true;