fix(core): handles with connectable false still considered valid
Signed-off-by: braks <78412429+bcakmakoglu@users.noreply.github.com>
This commit is contained in:
@@ -108,9 +108,10 @@ export function isValidHandle(
|
|||||||
|
|
||||||
// in strict mode we don't allow target to target or source to source connections
|
// in strict mode we don't allow target to target or source to source connections
|
||||||
const isValid =
|
const isValid =
|
||||||
handleToCheck.classList.contains('connectable') && connectionMode === ConnectionMode.Strict
|
handleToCheck.classList.contains('connectable') &&
|
||||||
|
(connectionMode === ConnectionMode.Strict
|
||||||
? (isTarget && handle.type === 'source') || (!isTarget && handle.type === 'target')
|
? (isTarget && handle.type === 'source') || (!isTarget && handle.type === 'target')
|
||||||
: handleNodeId !== fromNodeId || handleId !== fromHandleId
|
: handleNodeId !== fromNodeId || handleId !== fromHandleId)
|
||||||
|
|
||||||
if (isValid) {
|
if (isValid) {
|
||||||
result.isValid = isValidConnection(connection, {
|
result.isValid = isValidConnection(connection, {
|
||||||
|
|||||||
Reference in New Issue
Block a user