Free, simple, and intuitive online database diagram editor and SQL generator.
JavaScript databasedatabase-designdatabase-diagramdatabase-schemadbmldiagram-editoreditorer-diagramerderdiagramindexeddbmariadbmcporacle-databaseoracle-dbpostgresqlschema-designsqlsql-serversqlite
Fix relationship swap table crashing
1ilitce85bb66804b
diff --git a/src/components/EditorSidePanel/RelationshipsTab/RelationshipInfo.jsx b/src/components/EditorSidePanel/RelationshipsTab/RelationshipInfo.jsxindex bc184f10..fe9ec9ae 100644--- a/src/components/EditorSidePanel/RelationshipsTab/RelationshipInfo.jsx+++ b/src/components/EditorSidePanel/RelationshipsTab/RelationshipInfo.jsx@@ -139,11 +139,12 @@ export default function RelationshipInfo({ data }) {dataSource={[{key: "1",- foreign: `${tables[data.startTableId].name}(${- tables[data.startTableId].fields[data.startFieldId].name+ foreign: `${tables[data.startTableId]?.name}(${+ tables[data.startTableId].fields[data.startFieldId]+ ?.name})`,- primary: `${tables[data.endTableId].name}(${- tables[data.endTableId].fields[data.endFieldId].name+ primary: `${tables[data.endTableId]?.name}(${+ tables[data.endTableId].fields[data.endFieldId]?.name})`,},]}