1
0
mirror of https://github.com/bitwarden/server.git synced 2025-05-05 03:32:21 -05:00

disable send for release (#1019)

This commit is contained in:
Chad Scharf 2020-12-02 17:15:08 -05:00 committed by GitHub
parent c0781db333
commit 36195eb0c9
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -84,6 +84,7 @@ namespace Bit.Api.Controllers
[HttpPost("")] [HttpPost("")]
public async Task<SendResponseModel> Post([FromBody] SendRequestModel model) public async Task<SendResponseModel> Post([FromBody] SendRequestModel model)
{ {
throw new NotFoundException();
var userId = _userService.GetProperUserId(User).Value; var userId = _userService.GetProperUserId(User).Value;
var send = model.ToSend(userId, _sendService); var send = model.ToSend(userId, _sendService);
await _sendService.SaveSendAsync(send); await _sendService.SaveSendAsync(send);
@ -95,6 +96,7 @@ namespace Bit.Api.Controllers
[DisableFormValueModelBinding] [DisableFormValueModelBinding]
public async Task<SendResponseModel> PostFile() public async Task<SendResponseModel> PostFile()
{ {
throw new NotFoundException();
if (!Request?.ContentType.Contains("multipart/") ?? true) if (!Request?.ContentType.Contains("multipart/") ?? true)
{ {
throw new BadRequestException("Invalid content."); throw new BadRequestException("Invalid content.");