From 1a24e8d4b178bb28b21f6966c951c9beec332cab Mon Sep 17 00:00:00 2001 From: Sarah Jamie Lewis Date: Tue, 5 Jul 2022 20:41:16 -0700 Subject: [PATCH] Rename to GetScopedZonedAttributeKeys --- functionality/filesharing/filesharing_functionality.go | 2 +- peer/cwtch_peer.go | 2 +- peer/profile_interface.go | 3 ++- 3 files changed, 4 insertions(+), 3 deletions(-) diff --git a/functionality/filesharing/filesharing_functionality.go b/functionality/filesharing/filesharing_functionality.go index 890b214..e27e834 100644 --- a/functionality/filesharing/filesharing_functionality.go +++ b/functionality/filesharing/filesharing_functionality.go @@ -92,7 +92,7 @@ func (f *Functionality) DownloadFile(profile peer.CwtchPeer, conversationID int, // ReShareFiles given a profile we iterate through all existing fileshares and re-share them // if the time limit has not expired func (f *Functionality) ReShareFiles(profile peer.CwtchPeer) error { - keys, err := profile.GetScopedZonedAttributes(attr.LocalScope, attr.FilesharingZone) + keys, err := profile.GetScopedZonedAttributeKeys(attr.LocalScope, attr.FilesharingZone) if err != nil { return err } diff --git a/peer/cwtch_peer.go b/peer/cwtch_peer.go index 5b70016..b1fd470 100644 --- a/peer/cwtch_peer.go +++ b/peer/cwtch_peer.go @@ -186,7 +186,7 @@ func (cp *cwtchPeer) GetScopedZonedAttribute(scope attr.Scope, zone attr.Zone, k } // GetScopedZonedAttributes finds all keys associated with the given scope and zone -func (cp *cwtchPeer) GetScopedZonedAttributes(scope attr.Scope, zone attr.Zone) ([]string, error) { +func (cp *cwtchPeer) GetScopedZonedAttributeKeys(scope attr.Scope, zone attr.Zone) ([]string, error) { cp.mutex.Lock() defer cp.mutex.Unlock() scopedZonedKey := scope.ConstructScopedZonedPath(zone.ConstructZonedPath("")) diff --git a/peer/profile_interface.go b/peer/profile_interface.go index 2d73cdb..e2b02eb 100644 --- a/peer/profile_interface.go +++ b/peer/profile_interface.go @@ -81,7 +81,8 @@ type CwtchPeer interface { // scope.zone.key = value GetScopedZonedAttribute(scope attr.Scope, zone attr.Zone, key string) (string, bool) - GetScopedZonedAttributes(scope attr.Scope, zone attr.Zone) ([]string, error) + // GetScopedZonedAttributeKeys returns all keys associated with a given scope and zone + GetScopedZonedAttributeKeys(scope attr.Scope, zone attr.Zone) ([]string, error) AccessPeeringState ModifyPeeringState