follow golint suggestions

This commit is contained in:
chrislusf
2015-03-10 00:20:31 -07:00
parent b4cb8bfd27
commit b07d81fb08
26 changed files with 570 additions and 101 deletions

View File

@@ -32,8 +32,7 @@ func (m *ConcurrentReadMap) Get(key string, newEntry func() interface{}) interfa
if value, ok := m.Items[key]; ok {
m.rmutex.RUnlock()
return value
} else {
m.rmutex.RUnlock()
return m.initMapEntry(key, newEntry)
}
m.rmutex.RUnlock()
return m.initMapEntry(key, newEntry)
}

View File

@@ -1,3 +1,5 @@
package util
// Copyright 2011 Numerotron Inc.
// Use of this source code is governed by an MIT-style license
// that can be found in the LICENSE file.
@@ -6,7 +8,6 @@
// Contact us on twitter with any questions: twitter.com/stat_hat
// The jconfig package provides a simple, basic configuration file parser using JSON.
package util
import (
"bytes"

View File

@@ -26,8 +26,8 @@ func TestFolderWritable(folder string) (err error) {
func Readln(r *bufio.Reader) ([]byte, error) {
var (
isPrefix bool = true
err error = nil
isPrefix = true
err error
line, ln []byte
)
for isPrefix && err == nil {