From 4b0b0e44514001106a4c8de35af350a4af81a103 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E6=A9=99=E5=AD=90?= <454313500@qq.com> Date: Thu, 26 Dec 2024 23:02:10 +0800 Subject: [PATCH] =?UTF-8?q?fix:=20=E4=BF=AE=E6=AD=A3file=E4=B8=BA=E7=A9=BA?= =?UTF-8?q?=E6=8D=95=E8=8E=B7?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../rbac/Yi.Framework.Rbac.Application/Services/FileService.cs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Yi.Abp.Net8/module/rbac/Yi.Framework.Rbac.Application/Services/FileService.cs b/Yi.Abp.Net8/module/rbac/Yi.Framework.Rbac.Application/Services/FileService.cs index f7be6221..86c0891b 100644 --- a/Yi.Abp.Net8/module/rbac/Yi.Framework.Rbac.Application/Services/FileService.cs +++ b/Yi.Abp.Net8/module/rbac/Yi.Framework.Rbac.Application/Services/FileService.cs @@ -38,7 +38,7 @@ namespace Yi.Framework.Rbac.Application.Services public async Task Get([FromRoute] Guid code, [FromRoute] bool? isThumbnail) { var file = await _repository.GetAsync(x => x.Id == code); - var path = file.GetQueryFileSavePath(isThumbnail); + var path = file?.GetQueryFileSavePath(isThumbnail); if (path is null || !File.Exists(path)) { return new NotFoundResult();