Added metadata creation (#2086)
* Reworked metadata creation * Fix from PR * Removed consolelog
This commit is contained in:
@ -18,9 +18,7 @@ export const useSetObjectDataTableData = () => {
|
||||
|
||||
return useRecoilCallback(
|
||||
({ set, snapshot }) =>
|
||||
<T extends { node: { id: string } }>(newEntityArrayRaw: T[]) => {
|
||||
const newEntityArray = newEntityArrayRaw.map((entity) => entity.node);
|
||||
|
||||
<T extends { id: string }>(newEntityArray: T[]) => {
|
||||
for (const entity of newEntityArray) {
|
||||
const currentEntity = snapshot
|
||||
.getLoadable(entityFieldsFamilyState(entity.id))
|
||||
@ -33,9 +31,6 @@ export const useSetObjectDataTableData = () => {
|
||||
|
||||
const entityIds = newEntityArray.map((entity) => entity.id);
|
||||
|
||||
// eslint-disable-next-line no-console
|
||||
console.log({ newEntityArray, entityIds });
|
||||
|
||||
set(tableRowIdsState, (currentRowIds) => {
|
||||
if (JSON.stringify(currentRowIds) !== JSON.stringify(entityIds)) {
|
||||
return entityIds;
|
||||
|
||||
Reference in New Issue
Block a user