diff --git a/Notesnook.API/Controllers/S3Controller.cs b/Notesnook.API/Controllers/S3Controller.cs index 90bf2f1..c124375 100644 --- a/Notesnook.API/Controllers/S3Controller.cs +++ b/Notesnook.API/Controllers/S3Controller.cs @@ -56,7 +56,11 @@ namespace Notesnook.API.Controllers var fileSize = HttpContext.Request.ContentLength ?? 0; bool hasBody = fileSize > 0; - if (!hasBody) return Ok(Request.GetEncodedUrl()); + + if (!hasBody) + { + return Ok(Request.GetEncodedUrl() + "&access_token=" + Request.Headers.Authorization.ToString().Replace("Bearer ", "")); + } if (Constants.IS_SELF_HOSTED) await UploadFileAsync(userId, name, fileSize); else await UploadFileWithChecksAsync(userId, name, fileSize);