yansen 6 år sedan
förälder
incheckning
214bcdbff0
1 ändrade filer med 5 tillägg och 1 borttagningar
  1. 5
    1
      service/goods/orders.go

+ 5
- 1
service/goods/orders.go Visa fil

@@ -17,7 +17,7 @@ import (
17 17
 	"github.com/yl10/kit/guid"
18 18
 )
19 19
 
20
-var mtx sync.Mutex
20
+var mtx *sync.Mutex
21 21
 
22 22
 // Orders 下单
23 23
 func (s *GoodsServ) Orders(
@@ -595,3 +595,7 @@ func (s *GoodsServ) GetNewGoods(ordersID string) (*goods.OrdersWithGoods, error)
595 595
 
596 596
 	return order, nil
597 597
 }
598
+
599
+func init() {
600
+	mtx = new(sync.Mutex)
601
+}