mirror of
https://github.com/open-webui/open-webui
synced 2025-04-02 20:11:18 +00:00
fix: only append link with page attribute if metatada.page is available
This commit is contained in:
parent
8eb82265d0
commit
f69956bda8
@ -65,7 +65,7 @@
|
|||||||
<a
|
<a
|
||||||
class="hover:text-gray-500 hover:dark:text-gray-100 underline"
|
class="hover:text-gray-500 hover:dark:text-gray-100 underline"
|
||||||
href={document?.metadata?.file_id
|
href={document?.metadata?.file_id
|
||||||
? `/api/v1/files/${document?.metadata?.file_id}/content#page=${document?.metadata?.page + 1}`
|
? `/api/v1/files/${document?.metadata?.file_id}/content${document?.metadata?.page !== undefined ? `#page=${document.metadata.page + 1}` : ''}`
|
||||||
: document.source.name.includes('http')
|
: document.source.name.includes('http')
|
||||||
? document.source.name
|
? document.source.name
|
||||||
: `#`}
|
: `#`}
|
||||||
|
Loading…
Reference in New Issue
Block a user