소스 검색

fix: Initialize enableGoogleDriveIntegration with default value

Taylor Wilsdon (aider) 4 달 전
부모
커밋
1c7ff7b1dc
1개의 변경된 파일1개의 추가작업 그리고 1개의 파일을 삭제
  1. 1 1
      src/lib/components/admin/Settings/Documents.svelte

+ 1 - 1
src/lib/components/admin/Settings/Documents.svelte

@@ -249,7 +249,7 @@
 			fileMaxSize = res?.file.max_size ?? '';
 			fileMaxCount = res?.file.max_count ?? '';
 
-			enableGoogleDriveIntegration = res.enable_google_drive_integration;
+			enableGoogleDriveIntegration = res.enable_google_drive_integration ?? false;
 			console.log('Google Drive Integration onMount:', enableGoogleDriveIntegration);
 			if (enableGoogleDriveIntegration === undefined) {
 			    console.error('enableGoogleDriveIntegration is undefined onMount');