Пример #1
0
        internal VaultKeep CreateVaultKeep(VaultKeep newVK, string userId)
        {
            Vault data = _vaultsRepo.GetById(newVK.VaultId);

            if (data.CreatorId != userId)
            {
                throw new Exception("You cannot add a keep to vault that you dont own... from vaultkeepsService");
            }

            newVK.Id = _repo.CreateVaultKeep(newVK);
            return(newVK);
        }