mirror of
https://github.com/MindWorkAI/AI-Studio.git
synced 2026-02-13 03:21:37 +00:00
Switched to IsNullOrWhiteSpace
This commit is contained in:
parent
9fb2dbb691
commit
67e866b303
@ -6,7 +6,7 @@
|
||||
@T("Test how we load your file. Check the content before further processing.")
|
||||
</MudJustifiedText>
|
||||
|
||||
@if (FilePath == string.Empty)
|
||||
@if (string.IsNullOrWhiteSpace(this.FilePath))
|
||||
{
|
||||
<ReadFileContent Text="@T("Load file")" @bind-FileContent="@this.FileContent"/>
|
||||
}
|
||||
|
||||
@ -31,12 +31,11 @@ public partial class DocumentCheckDialog : MSGComponentBase
|
||||
|
||||
protected override async Task OnAfterRenderAsync(bool firstRender)
|
||||
{
|
||||
if (firstRender && !string.IsNullOrEmpty(this.FilePath))
|
||||
if (firstRender && !string.IsNullOrWhiteSpace(this.FilePath))
|
||||
{
|
||||
var fileContent = await UserFile.LoadFileData(this.FilePath, this.RustService, this.DialogService);
|
||||
this.FileContent = fileContent;
|
||||
this.StateHasChanged();
|
||||
}
|
||||
}
|
||||
|
||||
}
|
||||
Loading…
Reference in New Issue
Block a user