diff options
author | Adam Harrison <adamdharrison@gmail.com> | 2024-10-13 20:27:35 -0400 |
---|---|---|
committer | Adam Harrison <adamdharrison@gmail.com> | 2024-10-13 20:27:35 -0400 |
commit | 526c21d62b0688b6b5128cda72c35e4fcc996d91 (patch) | |
tree | 1a3165bbc2536306b4a414dc51921210c314eb2a /src/lpm.c | |
parent | 0cfe9e3c2bcd6fabd0c446cd03d60fd7d736ce19 (diff) | |
download | lite-xl-plugin-manager-526c21d62b0688b6b5128cda72c35e4fcc996d91.tar.gz lite-xl-plugin-manager-526c21d62b0688b6b5128cda72c35e4fcc996d91.zip |
Fixed issue with fetch not receiving final progress update.
Diffstat (limited to 'src/lpm.c')
-rw-r--r-- | src/lpm.c | 6 |
1 files changed, 5 insertions, 1 deletions
@@ -652,8 +652,12 @@ static int lpm_fetchk(lua_State* L, int status, lua_KContext ctx) { join_thread(context->thread); git_repository_free(context->repository); lua_pushstring(L, context->data[0] == 0 ? NULL : context->data); - if (context->callback_function) + if (context->callback_function) { + lua_rawgeti(L, LUA_REGISTRYINDEX, context->callback_function); + lua_pushboolean(L, 1); + lua_pcall(L, 1, 0, 0); luaL_unref(L, LUA_REGISTRYINDEX, context->callback_function); + } luaL_unref(L, LUA_REGISTRYINDEX, (int)ctx); if (context->error_code) { return lua_error(L); |