From 8ecb105414975257728e257cb4e15fe47587ff50 Mon Sep 17 00:00:00 2001 From: Sarah Jamie Lewis Date: Fri, 15 Oct 2021 12:43:28 -0700 Subject: [PATCH] Use constant.Tag instead of AttributeTag --- app/app.go | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) diff --git a/app/app.go b/app/app.go index 0d1c655..51d38a9 100644 --- a/app/app.go +++ b/app/app.go @@ -5,6 +5,7 @@ import ( "cwtch.im/cwtch/event" "cwtch.im/cwtch/model" "cwtch.im/cwtch/model/attr" + "cwtch.im/cwtch/model/constants" "cwtch.im/cwtch/peer" "cwtch.im/cwtch/protocol/connections" "cwtch.im/cwtch/storage" @@ -19,9 +20,6 @@ import ( "sync" ) -// AttributeTag is a const name for a peer attribute that can be set at creation time, for example for versioning info -const AttributeTag = "tag" - type applicationCore struct { eventBuses map[string]event.Manager @@ -132,7 +130,7 @@ func (app *application) CreateTaggedPeer(name string, password string, tag strin app.engines[profile.Onion] = engine if tag != "" { - p.SetScopedZonedAttribute(attr.LocalScope, attr.ProfileZone, AttributeTag, tag) + p.SetScopedZonedAttribute(attr.LocalScope, attr.ProfileZone, constants.Tag, tag) } app.appBus.Publish(event.NewEvent(event.NewPeer, map[event.Field]string{event.Identity: profile.Onion, event.Created: event.True}))