github.com/gitbundle/modules@v0.0.0-20231025071548-85b91c5c3b01/setting/federation.go (about) 1 // Copyright 2023 The GitBundle Inc. All rights reserved. 2 // Copyright 2017 The Gitea Authors. All rights reserved. 3 // Use of this source code is governed by a MIT-style 4 // license that can be found in the LICENSE file. 5 6 package setting 7 8 import "github.com/gitbundle/modules/log" 9 10 // Federation settings 11 var ( 12 Federation = struct { 13 Enabled bool 14 ShareUserStatistics bool 15 }{ 16 Enabled: false, 17 ShareUserStatistics: true, 18 } 19 ) 20 21 func newFederationService() { 22 if err := Cfg.Section("federation").MapTo(&Federation); err != nil { 23 log.Fatal("Failed to map Federation settings: %v", err) 24 } 25 }