Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 2 additions & 0 deletions cmd/lora-gateway-bridge/cmd/root.go
Original file line number Diff line number Diff line change
Expand Up @@ -32,6 +32,8 @@ func init() {
rootCmd.PersistentFlags().StringVarP(&cfgFile, "config", "c", "", "path to configuration file (optional)")
rootCmd.PersistentFlags().Int("log-level", 4, "debug=5, info=4, error=2, fatal=1, panic=0")

viper.BindPFlag("general.log_level", rootCmd.PersistentFlags().Lookup("log-level"))

// default values
viper.SetDefault("general.log_level", 4)
viper.SetDefault("backend.type", "semtech_udp")
Expand Down
2 changes: 0 additions & 2 deletions internal/backend/semtechudp/backend.go
Original file line number Diff line number Diff line change
Expand Up @@ -465,8 +465,6 @@ func (b *Backend) handlePushData(up udpPacket) error {

func (b *Backend) handleStats(gatewayID lorawan.EUI64, stats gw.GatewayStats) {
// set configuration version, if available
b.RLock()
defer b.RUnlock()

for _, c := range b.configurations {
if gatewayID == c.gatewayID {
Expand Down