gofmt all the things
This commit is contained in:
parent
0409bc7d6b
commit
f06bf129bb
16
scribble.go
16
scribble.go
@ -28,8 +28,8 @@ type (
|
|||||||
// Driver
|
// Driver
|
||||||
Driver struct {
|
Driver struct {
|
||||||
mutexes map[string]sync.Mutex
|
mutexes map[string]sync.Mutex
|
||||||
dir string
|
dir string
|
||||||
log hatchet.Logger
|
log hatchet.Logger
|
||||||
}
|
}
|
||||||
|
|
||||||
// Transaction represents
|
// Transaction represents
|
||||||
@ -46,15 +46,15 @@ func New(dir string, logger hatchet.Logger) (*Driver, error) {
|
|||||||
fmt.Printf("Creating database directory at '%v'...\n", dir)
|
fmt.Printf("Creating database directory at '%v'...\n", dir)
|
||||||
|
|
||||||
//
|
//
|
||||||
if logger == nil {
|
if logger == nil {
|
||||||
logger = hatchet.DevNullLogger{}
|
logger = hatchet.DevNullLogger{}
|
||||||
}
|
}
|
||||||
|
|
||||||
//
|
//
|
||||||
scribble := &Driver{
|
scribble := &Driver{
|
||||||
dir: dir,
|
dir: dir,
|
||||||
mutexes: make(map[string]sync.Mutex),
|
mutexes: make(map[string]sync.Mutex),
|
||||||
log: logger,
|
log: logger,
|
||||||
}
|
}
|
||||||
|
|
||||||
//
|
//
|
||||||
@ -109,7 +109,7 @@ func (d *Driver) write(trans Transaction) error {
|
|||||||
}
|
}
|
||||||
|
|
||||||
//
|
//
|
||||||
if err := ioutil.WriteFile(dir + "/" + trans.ResourceID, b, 0666); err != nil {
|
if err := ioutil.WriteFile(dir+"/"+trans.ResourceID, b, 0666); err != nil {
|
||||||
return err
|
return err
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user