diff options
author | bptato <nincsnevem662@gmail.com> | 2024-03-24 21:59:24 +0100 |
---|---|---|
committer | bptato <nincsnevem662@gmail.com> | 2024-03-24 21:59:24 +0100 |
commit | 00fa87199d70f5717446a32c04026880eccbbefa (patch) | |
tree | 1a9a8829ed64f48571b6c7638aa40e513f9f22d6 /src | |
parent | b03e646012739b2bd1444604504a869d7b252323 (diff) | |
download | chawan-00fa87199d70f5717446a32c04026880eccbbefa.tar.gz |
buffer: fix getTitle never returning in some cases
Diffstat (limited to 'src')
-rw-r--r-- | src/server/buffer.nim | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/src/server/buffer.nim b/src/server/buffer.nim index 13a7ea20..ddd85420 100644 --- a/src/server/buffer.nim +++ b/src/server/buffer.nim @@ -1159,6 +1159,8 @@ proc getTitle*(buffer: Buffer): string {.proxy, task.} = let title = buffer.document.findFirst(TAG_TITLE) if title != nil: return title.childTextContent.stripAndCollapse() + if buffer.state == bsLoaded: + return "" # title no longer expected buffer.savetask = true return "" |