mirror of
https://github.com/usebruno/bruno.git
synced 2024-11-08 00:54:10 +01:00
fix(#236): insomnia import fix
This commit is contained in:
parent
a849e4fb7b
commit
acff0c379e
@ -126,9 +126,7 @@ const parseInsomniaCollection = (data) => {
|
||||
try {
|
||||
const insomniaExport = JSON.parse(data);
|
||||
const insomniaResources = get(insomniaExport, 'resources', []);
|
||||
const insomniaCollection = insomniaResources.find(
|
||||
(resource) => resource._type === 'workspace' && resource.scope === 'collection'
|
||||
);
|
||||
const insomniaCollection = insomniaResources.find((resource) => resource._type === 'workspace');
|
||||
|
||||
if (!insomniaCollection) {
|
||||
reject(new BrunoError('Collection not found inside Insomnia export'));
|
||||
|
Loading…
Reference in New Issue
Block a user