浏览代码

Update inbound.go

fix expiry time
sprov 4 年之前
父节点
当前提交
500b08b112
共有 1 个文件被更改,包括 1 次插入1 次删除
  1. 1 1
      web/service/inbound.go

+ 1 - 1
web/service/inbound.go

@@ -167,7 +167,7 @@ func (s *InboundService) AddTraffic(traffics []*xray.Traffic) (err error) {
 
 func (s *InboundService) DisableInvalidInbounds() (int64, error) {
 	db := database.GetDB()
-	now := time.Now()
+	now := time.Now().Unix() * 1000
 	result := db.Model(model.Inbound{}).
 		Where("((total > 0 and up + down >= total) or (expiry_time > 0 and expiry_time <= ?)) and enable = ?", now, true).
 		Update("enable", false)