diff --git a/go.mod b/go.mod index 47e5b5d29..8a12cca93 100644 --- a/go.mod +++ b/go.mod @@ -16,7 +16,7 @@ require ( github.com/jmoiron/sqlx v1.4.0 github.com/lib/pq v1.10.9 github.com/nyaruka/ezconf v0.3.0 - github.com/nyaruka/gocommon v1.54.7 + github.com/nyaruka/gocommon v1.54.8 github.com/nyaruka/null/v3 v3.0.0 github.com/nyaruka/redisx v0.8.0 github.com/patrickmn/go-cache v2.1.0+incompatible diff --git a/go.sum b/go.sum index 35dee50de..032353245 100644 --- a/go.sum +++ b/go.sum @@ -71,8 +71,8 @@ github.com/naoina/toml v0.1.1 h1:PT/lllxVVN0gzzSqSlHEmP8MJB4MY2U7STGxiouV4X8= github.com/naoina/toml v0.1.1/go.mod h1:NBIhNtsFMo3G2szEBne+bO4gS192HuIYRqfvOWb4i1E= github.com/nyaruka/ezconf v0.3.0 h1:kGvJqVN8AHowb4HdaHAviJ0Z3yI5Pyekp1WqibFEaGk= github.com/nyaruka/ezconf v0.3.0/go.mod h1:89GUW6EPRNLIxT7lC4LWnjWTgZeQwRoX7lBmc8ralAU= -github.com/nyaruka/gocommon v1.54.7 h1:4JhoPM6bs05HWzJOEoy9rLKuBfUaH06wN7rMN0CKOzg= -github.com/nyaruka/gocommon v1.54.7/go.mod h1:rWkEIpYIK98zL9Qm6PeMXJ+84WcWlArf01RfuWWCYvQ= +github.com/nyaruka/gocommon v1.54.8 h1:mYZNY2KRsxhUDDw7ULG/Mui2FfHwuYZB7a+Ronb/Xuk= +github.com/nyaruka/gocommon v1.54.8/go.mod h1:rWkEIpYIK98zL9Qm6PeMXJ+84WcWlArf01RfuWWCYvQ= github.com/nyaruka/librato v1.1.1 h1:0nTYtJLl3Sn7lX3CuHsLf+nXy1k/tGV0OjVxLy3Et4s= github.com/nyaruka/librato v1.1.1/go.mod h1:fme1Fu1PT2qvkaBZyw8WW+SrnFe2qeeCWpvqmAaKAKE= github.com/nyaruka/null/v2 v2.0.3 h1:rdmMRQyVzrOF3Jff/gpU/7BDR9mQX0lcLl4yImsA3kw= diff --git a/handlers/rocketchat/handler.go b/handlers/rocketchat/handler.go index f7228afab..177b861f1 100644 --- a/handlers/rocketchat/handler.go +++ b/handlers/rocketchat/handler.go @@ -69,7 +69,7 @@ func (h *handler) receiveMessage(ctx context.Context, channel courier.Channel, w return nil, handlers.WriteAndLogRequestError(ctx, h, channel, w, r, errors.New("no text or attachment")) } - urn, err := urns.NewFromParts(urns.RocketChat.Prefix, payload.User.URN, "", payload.User.Username) + urn, err := urns.NewFromParts(urns.RocketChat.Prefix, payload.User.URN, nil, payload.User.Username) if err != nil { return nil, handlers.WriteAndLogRequestError(ctx, h, channel, w, r, err) } diff --git a/handlers/telegram/handler.go b/handlers/telegram/handler.go index a1b49fbdb..0ba66462a 100644 --- a/handlers/telegram/handler.go +++ b/handlers/telegram/handler.go @@ -58,7 +58,7 @@ func (h *handler) receiveMessage(ctx context.Context, channel courier.Channel, w date := time.Unix(payload.Message.Date, 0).UTC() // create our URN - urn, err := urns.NewFromParts(urns.Telegram.Prefix, strconv.FormatInt(payload.Message.From.ContactID, 10), "", strings.ToLower(payload.Message.From.Username)) + urn, err := urns.NewFromParts(urns.Telegram.Prefix, strconv.FormatInt(payload.Message.From.ContactID, 10), nil, strings.ToLower(payload.Message.From.Username)) if err != nil { return nil, handlers.WriteAndLogRequestError(ctx, h, channel, w, r, err) } diff --git a/handlers/twitter/handler.go b/handlers/twitter/handler.go index d505e6af8..3feebbbba 100644 --- a/handlers/twitter/handler.go +++ b/handlers/twitter/handler.go @@ -167,7 +167,7 @@ func (h *handler) receiveEvents(ctx context.Context, c courier.Channel, w http.R return nil, handlers.WriteAndLogRequestError(ctx, h, c, w, r, fmt.Errorf("unable to find user for id: %s", senderID)) } - urn, err := urns.NewFromParts(urns.TwitterID.Prefix, user.ID, "", strings.ToLower(user.ScreenName)) + urn, err := urns.NewFromParts(urns.TwitterID.Prefix, user.ID, nil, strings.ToLower(user.ScreenName)) if err != nil { return nil, handlers.WriteAndLogRequestError(ctx, h, c, w, r, errors.New("invalid twitter id")) }