public DataFlow SaveFlow(DataFlow instance, NodeVisit visit)
        {
            ValidateCanEditFlowById(visit, instance.Id);

            if ((instance == null))
            {
                throw new ArgumentException("Input values are null.");
            }

            instance.ModifiedById = visit.Account.Id;
            TransactionTemplate.Execute(delegate
            {
                _flowDao.Save(instance);
                ActivityManager.LogAudit(NodeMethod.None, instance.FlowName, visit, "{0} saved flow: {1}.",
                                         visit.Account.NaasAccount, instance.ToString());
                return(null);
            });
            return(instance);
        }