Skip to content

Commit

Permalink
Merge pull request #24 from kuuote/fix-available_plugins
Browse files Browse the repository at this point in the history
Fix all plugins are always available
  • Loading branch information
Shougo committed Jun 23, 2024
2 parents b9ae7f0 + a5c7953 commit 9ac3ae8
Showing 1 changed file with 8 additions and 5 deletions.
13 changes: 8 additions & 5 deletions denops/dpp/dpp.ts
Original file line number Diff line number Diff line change
Expand Up @@ -181,11 +181,14 @@ export class Dpp {

// Add plugins runtimepath
const depends = new Set<string>();
const availablePlugins = Object.values(recordPlugins).filter(async (
plugin,
) =>
plugin.path && await isDirectory(plugin.path) && await checkIf(plugin)
);
const availablePlugins = [];
for (const plugin of Object.values(recordPlugins)) {
if (
plugin.path && !await isDirectory(plugin.path) && await checkIf(plugin)
) {
availablePlugins.push(plugin);
}
}
const nonLazyPlugins = availablePlugins.filter((plugin) => !plugin.lazy);
const hookSources = [];
for (const plugin of nonLazyPlugins) {
Expand Down

0 comments on commit 9ac3ae8

Please sign in to comment.