Métodos Frequentes
Métodos Frequentes
Métodos Frequentes
Métodos Frequentes
public async Task <IActionResult> ChangePhoto(IFormCollection collection) { if (ModelState.IsValid && collection.Files[0] != null) { await _photoService.ChangePhotoAsync(new AddPhotoDto() { UserId = (int)HttpContext.Items["id"], UploadedFile = collection.Files[0] }); return(Ok()); } return(BadRequest()); }