Skip to content

Commit

Permalink
refactor: use is_async in list
Browse files Browse the repository at this point in the history
  • Loading branch information
Saghen committed Dec 11, 2024
1 parent 30705ab commit fe568eb
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion lua/blink/cmp/sources/lib/provider/list.lua
Original file line number Diff line number Diff line change
Expand Up @@ -52,7 +52,7 @@ function list.new(provider, context, on_items, opts)

-- if async, immediately send the default response/initial items
local is_async = self.provider.config.async(self.context)
if self.provider.config.async(self.context) and not self.has_completed then self:emit() end
if is_async and not self.has_completed then self:emit() end

-- if not async and timeout is set, send the default response after the timeout
local timeout_ms = self.provider.config.timeout_ms(self.context)
Expand Down

0 comments on commit fe568eb

Please sign in to comment.