Skip to content
This repository was archived by the owner on Apr 20, 2024. It is now read-only.

Commit 589e80e

Browse files
committed
Changed addConfigurable order
1 parent 69b6d77 commit 589e80e

File tree

1 file changed

+4
-1
lines changed

1 file changed

+4
-1
lines changed

Sources/Bugsnag/Provider.swift

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -13,6 +13,8 @@ public final class Provider: Vapor.Provider {
1313
}
1414

1515
public func boot(_ config: Config) throws {
16+
try config.addConfigurable(middleware: Middleware(config: config), name: "bugsnag")
17+
1618
guard let config: Config = config["bugsnag"] else {
1719
throw Abort(
1820
.internalServerError,
@@ -24,6 +26,8 @@ public final class Provider: Vapor.Provider {
2426
}
2527

2628
public init(config: Config) throws {
29+
try config.addConfigurable(middleware: Middleware(config: config), name: "bugsnag")
30+
2731
guard let config: Config = config["bugsnag"] else {
2832
throw Abort(
2933
.internalServerError,
@@ -32,7 +36,6 @@ public final class Provider: Vapor.Provider {
3236
}
3337

3438
self.config = try BugsnagConfig(config)
35-
try config.addConfigurable(middleware: Middleware(config: config), name: "bugsnag")
3639
}
3740

3841
// is automatically called directly after boot()

0 commit comments

Comments
 (0)