Fix add service for topology
This commit is contained in:
parent
14a5433a70
commit
5f89203333
@ -78,17 +78,9 @@ const updateSimulation = (
|
|||||||
};
|
};
|
||||||
});
|
});
|
||||||
|
|
||||||
const mappedLinks = nextLinks.map((nextLink, index) => {
|
const mappedLinks = nextLinks.map((nextLink, index) => ({
|
||||||
const simLink = simLinks.reduce((acc, l, i) => {
|
|
||||||
return nextLink.source === l.source && nextLink.target === l.target ?
|
|
||||||
l : acc;
|
|
||||||
}, {});
|
|
||||||
return simLink ? {
|
|
||||||
...simLink
|
|
||||||
} : {
|
|
||||||
...nextLink
|
...nextLink
|
||||||
};
|
}));
|
||||||
});
|
|
||||||
|
|
||||||
const {
|
const {
|
||||||
width,
|
width,
|
||||||
|
Loading…
Reference in New Issue
Block a user