Skip to content

Commit

Permalink
Merge pull request #806 from stakwork/update/second-brain-url
Browse files Browse the repository at this point in the history
Update/second brain url
  • Loading branch information
Evanfeenstra authored Mar 22, 2024
2 parents ca62559 + 36d4ebf commit e27d932
Show file tree
Hide file tree
Showing 9 changed files with 16 additions and 5 deletions.
1 change: 1 addition & 0 deletions dist/src/controllers/chatTribes.js

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion dist/src/controllers/chatTribes.js.map

Large diffs are not rendered by default.

1 change: 1 addition & 0 deletions dist/src/controllers/chats.js

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion dist/src/controllers/chats.js.map

Large diffs are not rendered by default.

6 changes: 4 additions & 2 deletions dist/src/utils/tribes.js

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion dist/src/utils/tribes.js.map

Large diffs are not rendered by default.

1 change: 1 addition & 0 deletions src/controllers/chatTribes.ts
Original file line number Diff line number Diff line change
Expand Up @@ -474,6 +474,7 @@ export async function editTribe(req: Req, res: Res): Promise<void | Response> {
owner_pubkey: owner.publicKey,
pin: pin || '',
profile_filters: profile_filters || '',
second_brain_url,
})
} catch (e) {
okToUpdate = false
Expand Down
1 change: 1 addition & 0 deletions src/controllers/chats.ts
Original file line number Diff line number Diff line change
Expand Up @@ -382,6 +382,7 @@ export async function createGroupChat(req: Req, res: Res): Promise<void> {
owner_route_hint: owner.routeHint || '',
pin: pin || '',
profile_filters: profile_filters || '',
second_brain_url: second_brain_url || '',
})
} catch (e) {
sphinxLogger.error(`=> couldnt create tribe ${e}`)
Expand Down
5 changes: 5 additions & 0 deletions src/utils/tribes.ts
Original file line number Diff line number Diff line change
Expand Up @@ -433,6 +433,7 @@ export interface TribeInterface {
owner_route_hint: string
pin: string
profile_filters?: string
second_brain_url?: string
}

export async function declare({
Expand All @@ -457,6 +458,7 @@ export async function declare({
owner_route_hint,
pin,
profile_filters,
second_brain_url,
}: TribeInterface): Promise<void> {
try {
let protocol = 'https'
Expand Down Expand Up @@ -484,6 +486,7 @@ export async function declare({
owner_route_hint: owner_route_hint || '',
pin: pin || '',
profile_filters,
second_brain_url,
}),
headers: { 'Content-Type': 'application/json' },
})
Expand Down Expand Up @@ -519,6 +522,7 @@ export async function edit({
owner_pubkey,
pin,
profile_filters,
second_brain_url,
}: TribeInterface): Promise<void> {
try {
const token = await genSignedTimestamp(owner_pubkey)
Expand Down Expand Up @@ -546,6 +550,7 @@ export async function edit({
owner_route_hint: owner_route_hint || '',
pin: pin || '',
profile_filters,
second_brain_url,
}),
headers: { 'Content-Type': 'application/json' },
})
Expand Down

0 comments on commit e27d932

Please sign in to comment.