Skip to content

Commit

Permalink
fix(BrowserStorage): don't create empty storage entries
Browse files Browse the repository at this point in the history
- chore: clean up empty storage entries on initializing

Signed-off-by: Maksim Sukharev <antreesy.web@gmail.com>
  • Loading branch information
Antreesy committed Mar 7, 2024
1 parent 900f043 commit 4a7b43b
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 1 deletion.
4 changes: 3 additions & 1 deletion src/stores/settings.js
Original file line number Diff line number Diff line change
Expand Up @@ -55,7 +55,9 @@ export const useSettingsStore = defineStore('settings', {

getters: {
getShowMediaSettings: (state) => (token) => {
if (state.showMediaSettings[token] !== undefined) {
if (!token) {
return true
} else if (state.showMediaSettings[token] !== undefined) {
return state.showMediaSettings[token]
}

Expand Down
2 changes: 2 additions & 0 deletions src/utils/webrtc/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -244,6 +244,8 @@ async function signalingJoinCall(token, flags, silent, recordingConsent) {
const virtualBackgroundBlurStrength = BrowserStorage.getItem('virtualBackgroundBlurStrength_' + token)
const virtualBackgroundUrl = BrowserStorage.getItem('virtualBackgroundUrl_' + token)

localMediaModel.set('token', token)

if (enableAudio) {
localMediaModel.enableAudio()
} else {
Expand Down

0 comments on commit 4a7b43b

Please sign in to comment.