Fix schema versions order (#1413)

This commit is contained in:
Oleg Shur 2022-01-19 17:24:12 +03:00 committed by GitHub
parent 5016a11333
commit d0761e2040
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -40,7 +40,10 @@ export const fetchSchemaVersions = createAsyncThunk<
}
);
const schemaVersionsAdapter = createEntityAdapter<SchemaSubject>();
const schemaVersionsAdapter = createEntityAdapter<SchemaSubject>({
selectId: ({ id }) => id,
sortComparer: (a, b) => b.id - a.id,
});
const schemasAdapter = createEntityAdapter<SchemaSubject>({
selectId: ({ subject }) => subject,
});