@data-fair/lib-vue 1.13.6 → 1.13.7

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (2) hide show
  1. package/package.json +1 -1
  2. package/session.js +3 -2
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@data-fair/lib-vue",
3
- "version": "1.13.6",
3
+ "version": "1.13.7",
4
4
  "description": "Composables and other utilities for Vue applications in the data-fair stack.",
5
5
  "main": "index.js",
6
6
  "files": [
package/session.js CHANGED
@@ -168,8 +168,9 @@ export async function getSession (initOptions) {
168
168
  goTo(redirect ?? options.logoutRedirectUrl ?? null)
169
169
  }
170
170
  const switchOrganization = (org, dep) => {
171
- if (org) { cookies.set('id_token_org', org, { path: cookiesPath }) } else { cookies.remove('id_token_org') }
172
- if (dep) { cookies.set('id_token_dep', dep, { path: cookiesPath }) } else { cookies.remove('id_token_dep') }
171
+ const cookieOpts = { path: cookiesPath }
172
+ if (org) { cookies.set('id_token_org', org, cookieOpts) } else { cookies.remove('id_token_org', cookieOpts) }
173
+ if (dep) { cookies.set('id_token_dep', dep, cookieOpts) } else { cookies.remove('id_token_dep', cookieOpts) }
173
174
  readState()
174
175
  }
175
176
  const setAdminMode = async (adminMode, redirect) => {