Skip to content

Commit

Permalink
Comment exported functions for WaitQueueTimeoutError
Browse files Browse the repository at this point in the history
  • Loading branch information
benjirewis committed Feb 2, 2021
1 parent b047752 commit 1e689d1
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions x/mongo/driver/topology/errors.go
Original file line number Diff line number Diff line change
Expand Up @@ -33,6 +33,7 @@ type WaitQueueTimeoutError struct {
Wrapped error
}

// Error implements the error interface.
func (w WaitQueueTimeoutError) Error() string {
errorMsg := "timed out while checking out a connection from connection pool"
if w.Wrapped != nil {
Expand All @@ -41,6 +42,7 @@ func (w WaitQueueTimeoutError) Error() string {
return errorMsg
}

// Unwrap returns the underlying error.
func (w WaitQueueTimeoutError) Unwrap() error {
return w.Wrapped
}

0 comments on commit 1e689d1

Please sign in to comment.