Don't read the file into memory
This commit is contained in:
parent
6ad5e8fb09
commit
8debda5c67
@ -36,8 +36,6 @@ public class PicController : ControllerBase
|
||||
string imageFileExtension = Path.GetExtension(item.PictureFileName);
|
||||
string mimetype = GetImageMimeTypeFromImageFileExtension(imageFileExtension);
|
||||
|
||||
var buffer = await System.IO.File.ReadAllBytesAsync(path);
|
||||
|
||||
return PhysicalFile(path, mimetype);
|
||||
}
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user