mirror of
https://github.com/Govor-team/Govor.git
synced 2026-07-21 19:54:55 +00:00
Add online pinging and friendship verification features
Introduces OnlinePingingController and related integration/unit tests for user online status updates. Adds PingHandlerService with memory cache throttling, IPingHandlerService interface, and service registration. Implements VerifyFriendship service and interface for friendship validation, with exception handling. Refactors CurrentUserService for improved user ID extraction and testability. Updates ChatsHub to verify friendship before messaging. Cleans up MediaController and optimizes UsersRepository queries by removing unnecessary includes.
This commit is contained in:
@@ -43,6 +43,9 @@ public static class ConfigurationProgramExtensions
|
||||
|
||||
services.AddHttpContextAccessor(); // it's very important for CurrentUserService
|
||||
services.AddScoped<ICurrentUserService, CurrentUserService>();
|
||||
|
||||
services.AddMemoryCache();
|
||||
services.AddScoped<IPingHandlerService, PingHandlerService>();
|
||||
}
|
||||
|
||||
public static void AddRepositories(this IServiceCollection services)
|
||||
|
||||
Reference in New Issue
Block a user