mirror of
https://github.com/jiriks74/presence.nvim
synced 2024-11-23 20:37:50 +01:00
Skip updates for unnamed buffers
This commit is contained in:
parent
c8ba01782e
commit
19764718e5
@ -515,6 +515,10 @@ Presence.update = Presence.discord_event(function(self, buffer, should_debounce)
|
|||||||
self:update_for_buffer(buffer, should_debounce)
|
self:update_for_buffer(buffer, should_debounce)
|
||||||
else
|
else
|
||||||
self.get_current_buffer(function(current_buffer)
|
self.get_current_buffer(function(current_buffer)
|
||||||
|
if not current_buffer or current_buffer == "" then
|
||||||
|
return self.log:debug("Current buffer not named, skipping...")
|
||||||
|
end
|
||||||
|
|
||||||
self:update_for_buffer(current_buffer, should_debounce)
|
self:update_for_buffer(current_buffer, should_debounce)
|
||||||
end)
|
end)
|
||||||
end
|
end
|
||||||
|
Loading…
x
Reference in New Issue
Block a user