diff --git a/package-lock.json b/package-lock.json index 8d391e4..b9651a7 100644 --- a/package-lock.json +++ b/package-lock.json @@ -3097,7 +3097,7 @@ "dependencies": { "@welshman/lib": "0.0.11", "@welshman/net": "0.0.14", - "@welshman/util": "0.0.20", + "@welshman/util": "0.0.21", "nostr-tools": "^2.7.0" }, "devDependencies": { @@ -3111,7 +3111,7 @@ "version": "0.0.12", "license": "MIT", "dependencies": { - "@welshman/util": "0.0.20" + "@welshman/util": "0.0.21" }, "devDependencies": { "gts": "^5.0.1", @@ -3149,7 +3149,7 @@ "license": "MIT", "dependencies": { "@welshman/lib": "0.0.11", - "@welshman/util": "0.0.20", + "@welshman/util": "0.0.21", "isomorphic-ws": "^5.0.0", "ws": "^8.16.0" }, @@ -3161,7 +3161,7 @@ }, "packages/util": { "name": "@welshman/util", - "version": "0.0.20", + "version": "0.0.21", "license": "MIT", "dependencies": { "@welshman/lib": "0.0.11", diff --git a/packages/dvm/package.json b/packages/dvm/package.json index 4ad2cc3..70ea42a 100644 --- a/packages/dvm/package.json +++ b/packages/dvm/package.json @@ -33,7 +33,7 @@ "dependencies": { "@welshman/lib": "0.0.11", "@welshman/net": "0.0.14", - "@welshman/util": "0.0.20", + "@welshman/util": "0.0.21", "nostr-tools": "^2.7.0" } } diff --git a/packages/feeds/package.json b/packages/feeds/package.json index 027add6..18f90b6 100644 --- a/packages/feeds/package.json +++ b/packages/feeds/package.json @@ -31,6 +31,6 @@ "typescript": "~5.1.6" }, "dependencies": { - "@welshman/util": "0.0.20" + "@welshman/util": "0.0.21" } } diff --git a/packages/lib/src/Tools.ts b/packages/lib/src/Tools.ts index 968c487..f6898f9 100644 --- a/packages/lib/src/Tools.ts +++ b/packages/lib/src/Tools.ts @@ -109,7 +109,7 @@ export const difference = (a: T[], b: T[]) => { return a.filter(x => !s.has(x)) } -export const remove = (a: T, b: T[]) => b.filter(x => x !== a) +export const remove = (a: T, xs: T[]) => xs.filter(x => x !== a) export const without = (a: T[], b: T[]) => b.filter(x => !a.includes(x)) diff --git a/packages/net/package.json b/packages/net/package.json index c26a04c..638c986 100644 --- a/packages/net/package.json +++ b/packages/net/package.json @@ -32,7 +32,7 @@ }, "dependencies": { "@welshman/lib": "0.0.11", - "@welshman/util": "0.0.20", + "@welshman/util": "0.0.21", "isomorphic-ws": "^5.0.0", "ws": "^8.16.0" } diff --git a/packages/util/package.json b/packages/util/package.json index f387147..848c999 100644 --- a/packages/util/package.json +++ b/packages/util/package.json @@ -1,6 +1,6 @@ { "name": "@welshman/util", - "version": "0.0.20", + "version": "0.0.21", "author": "hodlbod", "license": "MIT", "description": "A collection of nostr-related utilities.", diff --git a/packages/util/src/Kinds.ts b/packages/util/src/Kinds.ts index ec1dc11..4122ef5 100644 --- a/packages/util/src/Kinds.ts +++ b/packages/util/src/Kinds.ts @@ -119,6 +119,7 @@ export const NAMED_WIKI_RELAYS = 30102 export const NAMED_EMOJIS = 30030 export const NAMED_TOPICS = 30015 export const NAMED_ARTIFACTS = 30063 +export const NAMED_COMMUNITIES = 30064 export const BADGES = 30008 export const BADGE_DEFINITION = 30009 export const STALL = 30017