@symbo.ls/fetch 2.6.7 → 2.6.10

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/index.js +4 -2
  2. package/package.json +2 -2
package/index.js CHANGED
@@ -20,7 +20,9 @@ export const fetchIcon = async (el, s, { icon }) => {
20
20
  }
21
21
 
22
22
  export const syncSystem = (data, el, s) => {
23
- const { SYSTEM, STATE } = TMP_DATA[s.appKey]
23
+ let temporaryProject = TMP_DATA[s.appKey]
24
+ if (!temporaryProject) temporaryProject = {}
25
+ const { SYSTEM, STATE } = temporaryProject
24
26
  const { system, state } = data
25
27
 
26
28
  const defObjs = {
@@ -77,7 +79,7 @@ export const fetchUser = (el, s, options) => {
77
79
  const { projects } = data
78
80
  const userName = data.name
79
81
  if (projects) {
80
- const projectId = projects[0]
82
+ const projectId = projects[s.activeProject || 0]
81
83
  fetchProject(el, s, { userName, projectId, ...options })
82
84
  }
83
85
  })
package/package.json CHANGED
@@ -1,11 +1,11 @@
1
1
  {
2
2
  "name": "@symbo.ls/fetch",
3
- "version": "2.6.7",
3
+ "version": "2.6.10",
4
4
  "main": "index.js",
5
5
  "dependencies": {
6
6
  "@symbo.ls/based": "latest",
7
7
  "@symbo.ls/config-default": "latest",
8
8
  "@symbo.ls/temp-db": "latest"
9
9
  },
10
- "gitHead": "15a1535659649deb922f75cf1051bb47e697752d"
10
+ "gitHead": "06d272d1ac426959776d77844ae6fee84c8c687b"
11
11
  }