mirror of
https://github.com/Kong/insomnia
synced 2024-11-07 22:30:15 +00:00
fix: added import and export types (#4411)
This commit is contained in:
parent
7d3526940e
commit
7e1bdfc66f
@ -113,7 +113,7 @@ export async function exportRequestsHAR(
|
||||
}
|
||||
|
||||
const data = await har.exportHar(harRequests);
|
||||
trackSegmentEvent(SegmentEvent.dataExport);
|
||||
trackSegmentEvent(SegmentEvent.dataExport, { type: 'har' });
|
||||
return JSON.stringify(data, null, '\t');
|
||||
}
|
||||
|
||||
@ -247,7 +247,7 @@ export async function exportRequestsData(
|
||||
delete d.type;
|
||||
return d;
|
||||
});
|
||||
trackSegmentEvent(SegmentEvent.dataExport);
|
||||
trackSegmentEvent(SegmentEvent.dataExport, { type: format });
|
||||
|
||||
if (format.toLowerCase() === 'yaml') {
|
||||
return YAML.stringify(data);
|
||||
|
@ -321,7 +321,7 @@ export async function importRaw(
|
||||
}
|
||||
|
||||
await db.flushChanges();
|
||||
trackSegmentEvent(SegmentEvent.dataImport);
|
||||
trackSegmentEvent(SegmentEvent.dataImport, { type: resultsType.id });
|
||||
const importRequest: ImportResult = {
|
||||
source: resultsType && typeof resultsType.id === 'string' ? resultsType.id : 'unknown',
|
||||
summary: importedDocs,
|
||||
|
@ -111,7 +111,6 @@ class GitSyncDropdown extends PureComponent<Props, State> {
|
||||
}
|
||||
|
||||
async _handleOpen() {
|
||||
trackSegmentEvent(SegmentEvent.vcsSyncStart, vcsSegmentEventProperties('git', 'setup'));
|
||||
await this._refreshState();
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user