added getDialogIdFromNode helper