fix: return hash from nostr.build

This commit is contained in:
Kieran 2023-12-10 17:23:57 +00:00
parent d167579348
commit 5add66711a
Signed by: Kieran
GPG Key ID: DE71CEB3925BE941
2 changed files with 14 additions and 13 deletions

View File

@ -341,18 +341,18 @@ export function NoteCreator() {
onChange={e => {
note.update(
v =>
(v.selectedCustomRelays =
// set false if all relays selected
e.target.checked &&
(v.selectedCustomRelays =
// set false if all relays selected
e.target.checked &&
note.selectedCustomRelays &&
note.selectedCustomRelays.length == a.length - 1
? undefined
: // otherwise return selectedCustomRelays with target relay added / removed
a.filter(el =>
el === r
? e.target.checked
: !note.selectedCustomRelays || note.selectedCustomRelays.includes(el),
)),
? undefined
: // otherwise return selectedCustomRelays with target relay added / removed
a.filter(el =>
el === r
? e.target.checked
: !note.selectedCustomRelays || note.selectedCustomRelays.includes(el),
)),
);
}}
/>
@ -421,9 +421,9 @@ export function NoteCreator() {
onChange={e =>
note.update(
v =>
(v.zapSplits = arr.map((vv, ii) =>
ii === i ? { ...vv, weight: Number(e.target.value) } : vv,
)),
(v.zapSplits = arr.map((vv, ii) =>
ii === i ? { ...vv, weight: Number(e.target.value) } : vv,
)),
)
}
/>

View File

@ -40,6 +40,7 @@ export default async function NostrBuild(file: File | Blob, publisher?: EventPub
blurhash: res.blurhash,
width: res.dimensions.width,
height: res.dimensions.height,
hash: res.sha256
},
};
}