Skip to content

Commit

Permalink
fixup! feat(LinkShareSettings): respect force public conversations pa…
Browse files Browse the repository at this point in the history
…ssword config in set public type switch (conversation already created)
  • Loading branch information
DorraJaouad committed Dec 6, 2024
1 parent 36f5ab2 commit 445a876
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion src/services/conversationsService.js
Original file line number Diff line number Diff line change
Expand Up @@ -227,7 +227,7 @@ const setNotificationCalls = async function(token, level) {
* @param {string} token The token of the conversation to be removed from favorites
* @param {string} password The password to set for the conversation (optional, only if force password is enabled)
*/
const makeConversationPublic = async function(token, password = '') {
const makeConversationPublic = async function(token, password) {
const data = (hasTalkFeature(token, 'conversation-creation-password') && password)
? { password }
: undefined
Expand Down
2 changes: 1 addition & 1 deletion src/store/conversationsStore.spec.js
Original file line number Diff line number Diff line change
Expand Up @@ -648,7 +648,7 @@ describe('conversationsStore', () => {
allowGuests: true,
})

expect(makeConversationPublic).toHaveBeenCalledWith(testToken)
expect(makeConversationPublic).toHaveBeenCalledWith(testToken, undefined)

const changedConversation = store.getters.conversation(testToken)
expect(changedConversation.type).toEqual(CONVERSATION.TYPE.PUBLIC)
Expand Down

0 comments on commit 445a876

Please sign in to comment.