/callback
+ // Session is managed server-side via Passport.js + express-session (not Supabase)
} catch (error) {
console.error("Social Login Error", error);
setMessage(`Error logging in with ${provider}: ${error.message}`, "error");
diff --git a/client/JS/exportImport.js b/client/JS/exportImport.js
index 3f79678..9776c46 100644
--- a/client/JS/exportImport.js
+++ b/client/JS/exportImport.js
@@ -11,7 +11,7 @@ export function formatNotesAsText(notes) {
return notes
.map((note, index) => {
const title = note.title || "Untitled note";
- const tags = (note.tags || []).join(", ") || "none";
+ const tags = (Array.isArray(note.tags) ? note.tags : []).join(", ") || "none";
const created = note.createdAt || "";
const updated = note.updatedAt || "";
const content = stripHtml(note.content || "");
@@ -78,7 +78,7 @@ export function formatNotesAsMarkdown(notes) {
return notes.map((note) => {
const title = note.title || "Untitled";
const created = note.createdAt ? `*Created: ${note.createdAt}*` : "";
- const tags = (note.tags || []).length ? `**Tags:** ${note.tags.join(", ")}` : "";
+ const tags = (Array.isArray(note.tags) ? note.tags : []).length ? `**Tags:** ${note.tags.join(", ")}` : "";
const content = htmlToMarkdown(note.content);
return `# ${title}\n${created}\n${tags}\n\n${content}\n\n---\n`;
@@ -133,7 +133,7 @@ function printNotes(notes) {
Tags
- ${escapeHtml((note.tags || []).join(", ") || "No specific tags")}
+ ${escapeHtml((Array.isArray(note.tags) ? note.tags : []).join(", ") || "No specific tags")}
${note.folderId ? `