Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

PluginManager would abort loading plugins when encountering an error #3017

Merged
merged 1 commit into from Nov 22, 2021

Conversation

Supereg
Copy link
Member

@Supereg Supereg commented Nov 22, 2021

♻️ Current situation

Due to a refactored for-loop, #2915 introduced a regression where the PluginManager.ts would skip the rest of the plugin list if it encountered an error while loading a plugin.
This was due to a forgotten return statement in a previously closure based forEach loop.

💡 Proposed solution

This PR replaces the return with a continue statement.

⚙️ Release Notes

--

➕ Additional Information

The issue was reported in #3013.

Testing

--

Reviewer Nudging

Easy one.

CC: @ShogunPanda

@Supereg Supereg added the fix label Nov 22, 2021
@Supereg Supereg requested review from dgreif and oznu November 22, 2021 19:15
@coveralls
Copy link

Pull Request Test Coverage Report for Build 1491752211

  • 0 of 1 (0.0%) changed or added relevant line in 1 file are covered.
  • No unchanged relevant lines lost coverage.
  • Overall coverage remained the same at 24.918%

Changes Missing Coverage Covered Lines Changed/Added Lines %
src/pluginManager.ts 0 1 0.0%
Totals Coverage Status
Change from base Build 1491621461: 0.0%
Covered Lines: 377
Relevant Lines: 1283

💛 - Coveralls

Copy link
Contributor

@ShogunPanda ShogunPanda left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM!
Sorry for having missed this.

@bwp91
Copy link
Contributor

bwp91 commented Nov 22, 2021

If we could get this merged and released asap i think this will prevent a lot of grief on the homebridge issues/discord 😊

@Supereg Supereg merged commit 1b5d6ba into beta-1.3.7 Nov 22, 2021
@Supereg Supereg deleted the fix/plugin-loader-crash branch November 22, 2021 21:26
@Supereg Supereg restored the fix/plugin-loader-crash branch November 22, 2021 21:52
Supereg added a commit that referenced this pull request Nov 22, 2021
@Supereg Supereg deleted the fix/plugin-loader-crash branch November 22, 2021 21:55
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

4 participants