mirror of
https://github.com/Govor-team/Govor.git
synced 2026-07-21 11:44:56 +00:00
ChatGroup work
This commit is contained in:
@@ -1,8 +1,9 @@
|
||||
using Govor.Application.Interfaces.Messages;
|
||||
using Govor.Core.Models;
|
||||
|
||||
namespace Govor.API.Services;
|
||||
|
||||
public interface IGroupService
|
||||
public interface IGroupService : IMessageSendingService, IMessageManagementService
|
||||
{
|
||||
ChatGroup GetGroupByInvite(string code);
|
||||
}
|
||||
@@ -1,3 +1,3 @@
|
||||
namespace Govor.Application.Interfaces.Messages.Parameters;
|
||||
|
||||
public record Result(bool IsSuccess, Exception Exception);
|
||||
public record Result(bool IsSuccess, Exception Exception, Guid messageId);
|
||||
@@ -48,11 +48,12 @@ public class PrivateChatService : IChatService
|
||||
};
|
||||
|
||||
await _messages.AddAsync(message);
|
||||
return new Result(true, null);
|
||||
|
||||
return new Result(true, null, messageId);
|
||||
}
|
||||
catch (Exception ex)
|
||||
{
|
||||
return new Result(false, ex);
|
||||
return new Result(false, ex, Guid.Empty);
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user