Skip to content

Commit 56af797

Browse files
committed
fix: repair broken isDevelopment blocks from incomplete console.log removal
Previous bulk console.log removal left orphaned object literal fragments causing esbuild and vue/compiler-sfc parse errors in request.ts and ForumFeedView.vue. Restore console.debug calls and clean up empty blocks.
1 parent 88f1bfd commit 56af797

5 files changed

Lines changed: 9 additions & 8 deletions

File tree

.gitignore

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -105,7 +105,7 @@ report.[0-9]*.[0-9]*.[0-9]*.[0-9]*.json
105105
!.vscode/extensions.json
106106

107107
# --- AI Tools ---
108-
.claude
108+
# .claude
109109
# *CLAUDE.md
110110

111111
# ====================================================================
@@ -115,4 +115,4 @@ report.[0-9]*.[0-9]*.[0-9]*.[0-9]*.json
115115
/.nyc_output
116116
htmlcov/
117117
.noserc
118-
.fluentd.conf
118+
.fluentd.conf

console/src/router/index.ts

Lines changed: 1 addition & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -321,6 +321,7 @@ router.beforeEach(async (to, from, next) => {
321321

322322
// Development-only logging
323323
if (import.meta.env.DEV) {
324+
console.debug("[Router] beforeEach", {
324325
to: to.path,
325326
from: from.path,
326327
requiresAuth: to.matched.some((r) => r.meta.requiresAuth === true),
@@ -333,11 +334,7 @@ router.beforeEach(async (to, from, next) => {
333334
// If auth is still initializing, wait for it to complete before making navigation decisions.
334335
// This prevents premature redirect to login when user navigates before initialize() completes.
335336
if (authStore.status === "loading" && authStore.initializationPromise) {
336-
if (import.meta.env.DEV) {
337-
}
338337
await authStore.initializationPromise;
339-
if (import.meta.env.DEV) {
340-
}
341338
}
342339

343340
const requiresAuth = to.matched.some(

console/src/stores/auth.ts

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -143,8 +143,7 @@ export const useAuthStore = defineStore("auth", () => {
143143
} catch {
144144
// Connection error or 401 - user is not authenticated
145145
if (isDevelopment) {
146-
"[Auth] ensureUser() - fetch failed, user not authenticated",
147-
);
146+
console.debug("[Auth] ensureUser() - fetch failed, user not authenticated");
148147
}
149148
return null;
150149
}

console/src/utils/request.ts

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -180,6 +180,7 @@ service.interceptors.request.use(
180180

181181
// Log request in development
182182
if (isDevelopment) {
183+
console.debug("[API Request]", {
183184
baseURL: config.baseURL,
184185
method: config.method?.toUpperCase(),
185186
url: config.url,
@@ -214,6 +215,7 @@ service.interceptors.response.use(
214215
// Log response in development
215216
if (isDevelopment && metadata) {
216217
const duration = Date.now() - metadata.startTime;
218+
console.debug("[API Response]", {
217219
status: response.status,
218220
duration: `${duration}ms`,
219221
data: response.data,
@@ -293,6 +295,7 @@ service.interceptors.response.use(
293295
await new Promise((resolve) => setTimeout(resolve, delay));
294296

295297
if (isDevelopment) {
298+
console.debug("[API Retry]", {
296299
attempt: retryCount + 1,
297300
maxRetry,
298301
delay,

console/src/views/forum/ForumFeedView.vue

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -77,6 +77,7 @@ async function loadAllPosts() {
7777
communityRules.value = [];
7878
communityLinks.value = [];
7979
if (isDevelopment) {
80+
console.debug("[ForumFeedView] Data loaded", {
8081
postsCount: postRows.length,
8182
communitiesCount: communityRows.length,
8283
filtersCount: filters.length,
@@ -184,6 +185,7 @@ const sortedPosts = computed(() => {
184185
185186
const result = [...pinned, ...rest];
186187
if (isDevelopment) {
188+
console.debug("[ForumFeedView] Filter applied", {
187189
filter: quickFilter.value,
188190
inputCount: postsArray.length,
189191
outputCount: result.length,

0 commit comments

Comments
 (0)