Skip to content

Commit

Permalink
improve travis.yml and fix an unnecessary dependency
Browse files Browse the repository at this point in the history
  • Loading branch information
kataras committed Apr 22, 2018
1 parent 70db67d commit a5ecb92
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 6 deletions.
2 changes: 1 addition & 1 deletion .travis.yml
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ env:
global:
- GOCACHE=off
install:
- go get ./...
- go get -t ./...
script:
- go test -v -cover ./...
after_script:
Expand Down
8 changes: 3 additions & 5 deletions database.go
Original file line number Diff line number Diff line change
Expand Up @@ -3,8 +3,6 @@ package sessions
import (
"sync"
"time"

"github.com/kataras/iris/core/memstore"
)

// Database is the interface which all session databases should implement
Expand Down Expand Up @@ -39,17 +37,17 @@ type Database interface {
}

type mem struct {
values map[string]*memstore.Store
values map[string]*Store
mu sync.RWMutex
}

var _ Database = (*mem)(nil)

func newMemDB() Database { return &mem{values: make(map[string]*memstore.Store)} }
func newMemDB() Database { return &mem{values: make(map[string]*Store)} }

func (s *mem) Acquire(sid string, expires time.Duration) LifeTime {
s.mu.Lock()
s.values[sid] = new(memstore.Store)
s.values[sid] = new(Store)
s.mu.Unlock()
return LifeTime{}
}
Expand Down

0 comments on commit a5ecb92

Please sign in to comment.