Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 1 addition & 2 deletions src/CB.Accessors/Contracts/IChannelAccessor.cs
Original file line number Diff line number Diff line change
Expand Up @@ -11,8 +11,7 @@ public interface IChannelAccessor

Task<ChannelDto> CreateAsync(Channel entity);

Task<ChannelDto?> UpdateAsync(string id,
Channel entity);
Task<ChannelDto?> UpdateAsync(ChannelDto entity);

Task<bool> DeleteAsync(string id);
}
5 changes: 2 additions & 3 deletions src/CB.Accessors/Implementations/ChannelAccessor.cs
Original file line number Diff line number Diff line change
Expand Up @@ -37,12 +37,11 @@ await context
return mapper.Map<ChannelDto>(entity);
}

public async Task<ChannelDto?> UpdateAsync(string id,
Channel updated)
public async Task<ChannelDto?> UpdateAsync(ChannelDto updated)
{
var channel = await context
.Channels
.FindAsync(id)
.FirstOrDefaultAsync(x => x.Id == updated.Id)
.ConfigureAwait(false);

if (channel == null)
Expand Down
Loading
Loading