mirror of
https://github.com/MindWorkAI/AI-Studio.git
synced 2026-10-18 03:17:59 +00:00
Fixed issues with stored paths in chat templates (#727)
This commit is contained in:
1 parent
e49973497c
commit
c325ba0787
5 files changed
+23
-8
No files matched your search
@@ -53,6 +53,11 @@ public record FileAttachment(FileAttachmentType Type, string FileName, string Fi
|
||||
/// </remarks>
|
||||
public bool Exists => File.Exists(this.FilePath);
|
||||
|
||||
/// <summary>
|
||||
/// Rebuilds the attachment from its current file path so file type detection uses the latest rules.
|
||||
/// </summary>
|
||||
public FileAttachment Normalize() => FromPath(this.FilePath);
|
||||
|
||||
/// <summary>
|
||||
/// Creates a FileAttachment from a file path by automatically determining the type,
|
||||
/// extracting the filename, and reading the file size.
|
||||
|
||||
Reference in new issue
Block a user