Used the idg.Generator from github

This commit is contained in:
sm
2014-11-24 14:42:11 -08:00
parent 3eb76009ad
commit f86bacbd69
4 changed files with 6 additions and 65 deletions
+3 -2
View File
@@ -12,6 +12,7 @@ import (
"strings"
"sync"
"github.com/smcquay/idg"
"golang.org/x/net/websocket"
)
@@ -28,7 +29,7 @@ func (h JsonHandler) ServeHTTP(w http.ResponseWriter, req *http.Request) {
// Controller is the shepherd of a collection of games. The main package in
// server simply populates one of these and starts an http server.
type Controller struct {
Idg *IdGenerator
Idg *idg.Generator
Conf Config
Games MapLock
Memprofile string
@@ -40,7 +41,7 @@ type Controller struct {
// Controller.
func NewController(conf Config, mprof, pprof string) *http.ServeMux {
c := &Controller{
Idg: NewIdGenerator(),
Idg: idg.NewGenerator(),
Conf: conf,
Games: MapLock{
M: make(map[string]*Game),