Skip to content

Commit

Permalink
fix: missing nf res in registernf and type assertion in smf and amfue…
Browse files Browse the repository at this point in the history
… comment remove
  • Loading branch information
donald1218 committed Oct 25, 2024
1 parent db8f201 commit 70637f4
Show file tree
Hide file tree
Showing 3 changed files with 5 additions and 4 deletions.
6 changes: 3 additions & 3 deletions internal/context/amf_ue.go
Original file line number Diff line number Diff line change
Expand Up @@ -683,9 +683,9 @@ func (ue *AmfUe) CopyDataFromUeContextModel(ueContext *models.UeContext) {
if ue.AccessAndMobilitySubscriptionData == nil {
ue.AccessAndMobilitySubscriptionData = new(models.AccessAndMobilitySubscriptionData)
}
// if ue.AccessAndMobilitySubscriptionData.SubscribedUeAmbr == nil {
// ue.AccessAndMobilitySubscriptionData.SubscribedUeAmbr = new(models.AmbrRm)
// }
if ue.AccessAndMobilitySubscriptionData.SubscribedUeAmbr == nil {
ue.AccessAndMobilitySubscriptionData.SubscribedUeAmbr = new(models.AmbrRm)
}

subAmbr := ue.AccessAndMobilitySubscriptionData.SubscribedUeAmbr
subAmbr.Uplink = ueContext.SubUeAmbr.Uplink
Expand Down
1 change: 1 addition & 0 deletions internal/sbi/consumer/nrf_service.go
Original file line number Diff line number Diff line change
Expand Up @@ -276,6 +276,7 @@ func (s *nnrfService) SendRegisterNFInstance(ctx context.Context, nrfUri, nfInst
} else {
// NFRegister
resourceUri := res.Location
nf = res.NrfNfManagementNfProfile
index := strings.Index(resourceUri, "/nnrf-nfm/")
if index >= 0 {
resouceNrfUri = resourceUri[:index]
Expand Down
2 changes: 1 addition & 1 deletion internal/sbi/consumer/smf_service.go
Original file line number Diff line number Diff line change
Expand Up @@ -178,7 +178,7 @@ func (s *nsmfService) SendCreateSmContextRequest(ue *amf_context.AmfUe, smContex
err1 = localErr
if apiErr, ok := localErr.(openapi.GenericOpenAPIError); ok {
// API error
posterr := apiErr.Model().(*Nsmf_PDUSession.PostSmContextsError)
posterr := apiErr.Model().(Nsmf_PDUSession.PostSmContextsError)
problemDetail = &posterr.ProblemDetails
errorResponse = &posterr.PostSmContextsError
}
Expand Down

0 comments on commit 70637f4

Please sign in to comment.