Make function to increase profile revision counter internal
This commit is contained in:
@@ -92,7 +92,7 @@ func startProfileUpdateChecker() error {
|
||||
// Always increase the revision counter of the layer profile.
|
||||
// This marks previous connections in the UI as decided with outdated settings.
|
||||
if activeProfile.layeredProfile != nil {
|
||||
activeProfile.layeredProfile.IncreaseRevisionCounter(true)
|
||||
activeProfile.layeredProfile.increaseRevisionCounter(true)
|
||||
}
|
||||
|
||||
// If the profile is saved externally (eg. via the API), have the
|
||||
|
||||
@@ -165,8 +165,9 @@ func (lp *LayeredProfile) LocalProfile() *Profile {
|
||||
return lp.localProfile
|
||||
}
|
||||
|
||||
// RevisionCnt returns the current profile revision counter.
|
||||
func (lp *LayeredProfile) IncreaseRevisionCounter(lock bool) (revisionCounter uint64) {
|
||||
// increaseRevisionCounter increases the revision counter and pushes the
|
||||
// layered profile to listeners.
|
||||
func (lp *LayeredProfile) increaseRevisionCounter(lock bool) (revisionCounter uint64) {
|
||||
if lp == nil {
|
||||
return 0
|
||||
}
|
||||
@@ -260,7 +261,7 @@ func (lp *LayeredProfile) Update() (revisionCounter uint64) {
|
||||
lp.updateCaches()
|
||||
|
||||
// bump revision counter
|
||||
lp.IncreaseRevisionCounter(false)
|
||||
lp.increaseRevisionCounter(false)
|
||||
}
|
||||
|
||||
return lp.RevisionCounter
|
||||
|
||||
Reference in New Issue
Block a user