mirror of
https://github.com/spacebarchat/server.git
synced 2026-05-11 19:04:51 +00:00
CDN-CS: support passing a bin path as cdn worker -> forks a new proc
This commit is contained in:
@@ -11,7 +11,7 @@ namespace Spacebar.Cdn.Controllers;
|
||||
public class UserController(LruFileCache lfc, IFileSource fs, CdnWorkerService cws) : ControllerBase {
|
||||
[HttpGet("/avatars/{userId}/{hash}")]
|
||||
[HttpGet("/avatars/{userId}/{hash}.{ext}")]
|
||||
public async Task<IActionResult> GetUserAvatar(string userId, string hash, string ext = "png") {
|
||||
public async Task<IActionResult> GetUserAvatar(string userId, string hash, string ext = "webp") {
|
||||
DiscordImageResizeParams resizeParams = Request.GetResizeParams();
|
||||
var originalKey = fs.BaseUrl + Request.Path;
|
||||
var cacheKey = Request.Path + resizeParams.ToSerializedName();
|
||||
|
||||
Reference in New Issue
Block a user