mirror of
https://github.com/Mintplex-Labs/anything-llm.git
synced 2025-04-17 18:18:11 +00:00
parent
1c549e2844
commit
2d700b13f6
1 changed files with 1 additions and 1 deletions
|
@ -12,7 +12,7 @@ export function getFileExtension(path) {
|
|||
}
|
||||
|
||||
export function middleTruncate(str, n) {
|
||||
const fileExtensionPattern = /(\..+)$/;
|
||||
const fileExtensionPattern = /([^.]*)$/;
|
||||
const extensionMatch = str.match(fileExtensionPattern);
|
||||
|
||||
if (str.length <= n) return str;
|
||||
|
|
Loading…
Add table
Reference in a new issue