fix: align backend APIs and upload flow
This commit is contained in:
@@ -0,0 +1,11 @@
|
||||
using ContactService.Infrastructure;
|
||||
using Microsoft.AspNetCore.Mvc;
|
||||
using Microsoft.EntityFrameworkCore;
|
||||
|
||||
namespace ContactService.WebApi.Controllers;
|
||||
[ApiController, Route("internal/management")]
|
||||
public sealed class ManagementController(ContactDbContext db) : ControllerBase
|
||||
{
|
||||
[HttpGet("relation/{owner:guid}/{target:guid}")]
|
||||
public async Task<object> Relation(Guid owner, Guid target) => new { related = await db.Friends.AnyAsync(x => x.Owner.Id == owner && x.Target.Id == target) };
|
||||
}
|
||||
Reference in New Issue
Block a user