fix(scraper): minor credential interop
This commit is contained in:
parent
b53c8ca44e
commit
27d7a4e6b5
1 changed files with 2 additions and 3 deletions
|
|
@ -35,9 +35,7 @@ local function prompt_credentials(platform, callback)
|
|||
logger.log('Submit cancelled', { level = vim.log.levels.WARN })
|
||||
return
|
||||
end
|
||||
local creds = { username = username, password = password }
|
||||
cache.set_credentials(platform, creds)
|
||||
callback(creds)
|
||||
callback({ username = username, password = password })
|
||||
end
|
||||
)
|
||||
end
|
||||
|
|
@ -111,6 +109,7 @@ function M.submit(opts)
|
|||
function(result)
|
||||
vim.schedule(function()
|
||||
if result and result.success then
|
||||
cache.set_credentials(platform, creds)
|
||||
logger.log('Submitted successfully', { level = vim.log.levels.INFO, override = true })
|
||||
else
|
||||
local err = result and result.error or 'unknown error'
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue