MCPcopy Index your code
hub / github.com/FlowiseAI/Flowise / getUserHome

Function getUserHome

packages/server/src/utils/index.ts:114–126  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

112 *
113 */
114export const getUserHome = (): string => {
115 let variableName = 'HOME'
116 if (process.platform === 'win32') {
117 variableName = 'USERPROFILE'
118 }
119
120 if (process.env[variableName] === undefined) {
121 // If for some reason the variable does not exist
122 // fall back to current folder
123 return process.cwd()
124 }
125 return process.env[variableName] as string
126}
127
128/**
129 * Returns the path of node modules package

Callers 5

initFunction · 0.90
getEncryptionKeyFunction · 0.70
getAuthSecretsDirectoryFunction · 0.70
getUploadPathFunction · 0.70

Calls

no outgoing calls

Tested by

no test coverage detected