Skip to content

Commit

Permalink
fix: remove GetConsumer() and add http.NotImplement
Browse files Browse the repository at this point in the history
  • Loading branch information
TYuan0816 committed Jun 22, 2024
1 parent 60a2dde commit 4fdd4bd
Show file tree
Hide file tree
Showing 3 changed files with 2 additions and 9 deletions.
2 changes: 1 addition & 1 deletion internal/sbi/api_sorprotection.go
Original file line number Diff line number Diff line change
Expand Up @@ -22,5 +22,5 @@ func (s *Server) getSorprotectionRoutes() []Route {
}

func (s *Server) SupiUeSorPost(c *gin.Context) {
c.JSON(http.StatusOK, gin.H{})
c.JSON(http.StatusNotImplemented, gin.H{})
}
2 changes: 1 addition & 1 deletion internal/sbi/api_upuprotection.go
Original file line number Diff line number Diff line change
Expand Up @@ -22,5 +22,5 @@ func (s *Server) getUpuprotectionRoutes() []Route {
}

func (s *Server) SupiUeUpuPost(c *gin.Context) {
c.JSON(http.StatusOK, gin.H{})
c.JSON(http.StatusNotImplemented, gin.H{})
}
7 changes: 0 additions & 7 deletions internal/sbi/consumer/consumer.go
Original file line number Diff line number Diff line change
Expand Up @@ -7,8 +7,6 @@ import (
"github.com/free5gc/openapi/Nudm_UEAuthentication"
)

var consumer *Consumer

type ConsumerAusf interface {
app.App
}
Expand All @@ -20,10 +18,6 @@ type Consumer struct {
*nudmService
}

func GetConsumer() *Consumer {
return consumer
}

func NewConsumer(ausf ConsumerAusf) (*Consumer, error) {
c := &Consumer{
ConsumerAusf: ausf,
Expand All @@ -40,6 +34,5 @@ func NewConsumer(ausf ConsumerAusf) (*Consumer, error) {
ueauClients: make(map[string]*Nudm_UEAuthentication.APIClient),
}

consumer = c
return c, nil
}

0 comments on commit 4fdd4bd

Please sign in to comment.