Remove SaveChanges...
This commit is contained in:
parent
a49c5229b8
commit
20d47800a9
|
|
@ -96,7 +96,7 @@ namespace TIAM.Database.DataLayers.Admins
|
||||||
{
|
{
|
||||||
userProductMapping = ctx.AddUserProductMapping(userProductMappingId, userId, productId, permissions, userProductToCars);
|
userProductMapping = ctx.AddUserProductMapping(userProductMappingId, userId, productId, permissions, userProductToCars);
|
||||||
|
|
||||||
return userProductMapping != null && ctx.SaveChanges() > 0;
|
return userProductMapping != null;
|
||||||
});
|
});
|
||||||
|
|
||||||
return isSucces ? userProductMapping : null;
|
return isSucces ? userProductMapping : null;
|
||||||
|
|
@ -113,7 +113,7 @@ namespace TIAM.Database.DataLayers.Admins
|
||||||
{
|
{
|
||||||
userProductMapping = ctx.UpdateUserProductMapping(userProductMappingId, permissions, userProductToCars);
|
userProductMapping = ctx.UpdateUserProductMapping(userProductMappingId, permissions, userProductToCars);
|
||||||
|
|
||||||
return userProductMapping != null && ctx.SaveChanges() > 0;
|
return userProductMapping != null;
|
||||||
});
|
});
|
||||||
|
|
||||||
return isSucces ? userProductMapping : null;
|
return isSucces ? userProductMapping : null;
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue