Manage the update of some data at the
start of the database
This commit is contained in:
@@ -1,7 +1,6 @@
|
||||
using skydiveLogs_api.Domain;
|
||||
using skydiveLogs_api.DomainBusiness.Interfaces;
|
||||
using skydiveLogs_api.DomainService.Repositories;
|
||||
using skydiveLogs_api.Infrastructure;
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Linq;
|
||||
@@ -55,12 +54,12 @@ namespace skydiveLogs_api.DomainBusiness
|
||||
return allJumpTypes.Single(g => g.Id == id);
|
||||
}
|
||||
|
||||
public bool UpdateJumpType(int id, JumpType jumpType)
|
||||
public bool UpdateJumpType(int id, JumpType jumpType, bool resetCache = true)
|
||||
{
|
||||
jumpType.Id = id;
|
||||
|
||||
var result = _jumpTypeRepository.Update(jumpType);
|
||||
if (result)
|
||||
if (resetCache && result)
|
||||
_cacheService.Delete(CacheType.JumpType);
|
||||
|
||||
return result;
|
||||
|
||||
Reference in New Issue
Block a user