mirror of
https://github.com/gravitl/netmaker.git
synced 2025-10-07 01:36:23 +08:00
transplanted join.
This commit is contained in:
@@ -4,9 +4,11 @@ package logic
|
||||
import (
|
||||
"encoding/base64"
|
||||
"encoding/json"
|
||||
"log"
|
||||
"strconv"
|
||||
"strings"
|
||||
"time"
|
||||
|
||||
"github.com/gravitl/netmaker/database"
|
||||
"github.com/gravitl/netmaker/dnslogic"
|
||||
"github.com/gravitl/netmaker/functions"
|
||||
@@ -290,3 +292,10 @@ func setPeerInfo(node models.Node) models.Node {
|
||||
peer.IsPending = node.IsPending
|
||||
return peer
|
||||
}
|
||||
|
||||
func Log(message string, loglevel int) {
|
||||
log.SetFlags(log.Flags() &^ (log.Llongfile | log.Lshortfile))
|
||||
if int32(loglevel) <= servercfg.GetVerbose() && servercfg.GetVerbose() != 0 {
|
||||
log.Println(message)
|
||||
}
|
||||
}
|
||||
|
Reference in New Issue
Block a user