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

fix: log error correctly #2552

Merged
merged 2 commits into from
May 17, 2024
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions packages/libp2p/src/upgrader.ts
Original file line number Diff line number Diff line change
Expand Up @@ -641,7 +641,7 @@ export class DefaultUpgrader implements Upgrader {
protocol
}
} catch (err: any) {
connection.log.error('encrypting inbound connection to %p failed', err)
connection.log.error('encrypting inbound connection failed', err)
throw new CodeError(err.message, codes.ERR_ENCRYPTION_FAILED)
}
}
Expand Down Expand Up @@ -678,7 +678,7 @@ export class DefaultUpgrader implements Upgrader {
protocol
}
} catch (err: any) {
connection.log.error('encrypting outbound connection to %p failed', err)
connection.log.error('encrypting outbound connection to %p failed', remotePeerId, err)
throw new CodeError(err.message, codes.ERR_ENCRYPTION_FAILED)
}
}
Expand Down
Loading