aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorAdam Soltys <[email protected]>2024-12-31 16:52:14 -0800
committerAdam Soltys <[email protected]>2024-12-31 16:52:14 -0800
commite2db9a0e0fad4cb107e1bb4fee32b0618f6bae26 (patch)
tree460c4efb7fd8f25ada1478114107f7c9b339cda9
parenta323fa03caf05332cfd0f72539532b9a2ed86221 (diff)
downloadcoinos-server-e2db9a0e0fad4cb107e1bb4fee32b0618f6bae26.tar.gz
coinos-server-e2db9a0e0fad4cb107e1bb4fee32b0618f6bae26.zip
picture not profile
-rw-r--r--lib/ecash.ts2
-rw-r--r--lib/migrate.ts4
-rw-r--r--lib/upload.ts6
-rw-r--r--lib/whitelist.ts1
-rw-r--r--routes/users.ts6
5 files changed, 8 insertions, 11 deletions
diff --git a/lib/ecash.ts b/lib/ecash.ts
index ade7f220..5a5776b5 100644
--- a/lib/ecash.ts
+++ b/lib/ecash.ts
@@ -7,13 +7,11 @@ import {
CashuWallet,
MintQuoteState,
PaymentRequest,
- PaymentRequestTransport,
PaymentRequestTransportType,
getDecodedToken,
getEncodedToken,
getEncodedTokenV4,
} from "@cashu/cashu-ts";
-import { v4 } from "uuid";
const { URL } = process.env;
const m = new CashuMint(config.mintUrl);
diff --git a/lib/migrate.ts b/lib/migrate.ts
index e0ec3b1e..403e22b1 100644
--- a/lib/migrate.ts
+++ b/lib/migrate.ts
@@ -1,6 +1,6 @@
-import { err, warn, l, line } from "$lib/logging";
-import { types } from "$lib/payments";
import { archive, db, g, ga, s } from "$lib/db";
+import { err, l, line, warn } from "$lib/logging";
+import { types } from "$lib/payments";
const queued = {};
const migrating = {};
diff --git a/lib/upload.ts b/lib/upload.ts
index bc358ede..ed06d7e0 100644
--- a/lib/upload.ts
+++ b/lib/upload.ts
@@ -1,8 +1,8 @@
-import { fileTypeFromBuffer } from "file-type";
-import { writeFileSync } from "fs";
-import { bail, fail } from "$lib/utils";
import { createHash } from "crypto";
+import { writeFileSync } from "fs";
import { err } from "$lib/logging";
+import { bail, fail } from "$lib/utils";
+import { fileTypeFromBuffer } from "file-type";
const sharp = require("sharp");
diff --git a/lib/whitelist.ts b/lib/whitelist.ts
index 16594a4b..01e4ef72 100644
--- a/lib/whitelist.ts
+++ b/lib/whitelist.ts
@@ -1,4 +1,5 @@
export default [
+ "about",
"admin",
"anon",
"autowithdraw",
diff --git a/routes/users.ts b/routes/users.ts
index d2992d1b..7635af20 100644
--- a/routes/users.ts
+++ b/routes/users.ts
@@ -127,7 +127,6 @@ export default {
"memoPrompt",
"npub",
"picture",
- "profile",
"prompt",
"pubkey",
"username",
@@ -151,7 +150,6 @@ export default {
if (!body.user) fail("no user object provided");
let { user } = body;
const fields = [
- "profile",
"cipher",
"pubkey",
"password",
@@ -269,7 +267,7 @@ export default {
"nip5",
"notify",
"nsec",
- "profile",
+ "picture",
"prompt",
"pubkey",
"push",
@@ -506,7 +504,7 @@ export default {
if (~i) contacts.splice(i, 1);
let u = await g(`user:${ref}`);
if (typeof u === "string") u = await g(`user:${ref}`);
- if (u) contacts.unshift(pick(u, ["id", "profile", "username"]));
+ if (u) contacts.unshift(pick(u, ["id", "picture", "username"]));
}
await s(`${id}:contacts`, contacts);