mirror of
https://github.com/Kong/insomnia
synced 2024-11-08 06:39:48 +00:00
Revert entity loading to use model.all() (Fixes #1582)
This commit is contained in:
parent
a4f56ffe7d
commit
8d9352aaec
@ -112,3 +112,7 @@ function _diffRequests(rOld: Request | null, rNew: Request): boolean {
|
||||
|
||||
return false;
|
||||
}
|
||||
|
||||
export function all(): Promise<Array<RequestVersion>> {
|
||||
return db.all(type);
|
||||
}
|
||||
|
@ -48,19 +48,19 @@ export const reducer = combineReducers({
|
||||
async function getAllDocs() {
|
||||
// Restore docs in parent->child->grandchild order
|
||||
const allDocs = [
|
||||
...(await db.all(models.settings.type)),
|
||||
...(await db.all(models.workspace.type)),
|
||||
...(await db.all(models.workspaceMeta.type)),
|
||||
...(await db.all(models.environment.type)),
|
||||
...(await db.all(models.cookieJar.type)),
|
||||
...(await db.all(models.requestGroup.type)),
|
||||
...(await db.all(models.requestGroupMeta.type)),
|
||||
...(await db.all(models.request.type)),
|
||||
...(await db.all(models.requestMeta.type)),
|
||||
...(await db.all(models.requestVersion.type)),
|
||||
...(await db.all(models.response.type)),
|
||||
...(await db.all(models.oAuth2Token.type)),
|
||||
...(await db.all(models.clientCertificate.type)),
|
||||
...(await models.settings.all()),
|
||||
...(await models.workspace.all()),
|
||||
...(await models.workspaceMeta.all()),
|
||||
...(await models.environment.all()),
|
||||
...(await models.cookieJar.all()),
|
||||
...(await models.requestGroup.all()),
|
||||
...(await models.requestGroupMeta.all()),
|
||||
...(await models.request.all()),
|
||||
...(await models.requestMeta.all()),
|
||||
...(await models.requestVersion.all()),
|
||||
...(await models.response.all()),
|
||||
...(await models.oAuth2Token.all()),
|
||||
...(await models.clientCertificate.all()),
|
||||
];
|
||||
|
||||
return allDocs;
|
||||
|
Loading…
Reference in New Issue
Block a user