fix(#251): Uses os.release to get correct pathsep for windows

This commit is contained in:
Jack Scotson 2023-10-08 10:47:34 +01:00
parent e83c2da798
commit 094bf7bc60

View File

@ -1,4 +1,3 @@
import path from 'path';
import { uuid } from 'utils/common';
import find from 'lodash/find';
import map from 'lodash/map';
@ -24,8 +23,9 @@ import {
} from 'utils/collections';
import { parseQueryParams, stringifyQueryParams } from 'utils/url';
import { getSubdirectoriesFromRoot, getDirectoryName } from 'utils/common/platform';
import os from 'os';
const PATH_SEPARATOR = path.sep;
const PATH_SEPARATOR = /Windows/i.test(os.release()) ? '\\' : '/';
const initialState = {
collections: []