From 4190e1f5f45068e9d1d983cf11b2c1c73245a277 Mon Sep 17 00:00:00 2001 From: zherr Date: Fri, 6 May 2016 15:26:14 -0500 Subject: [PATCH] RefTagID is not known to BusinessMessageReject type --- session.go | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/session.go b/session.go index 33debc4fd..e64238d79 100644 --- a/session.go +++ b/session.go @@ -468,6 +468,10 @@ func (s *session) doReject(msg Message, rej MessageRejectError) { case rej.RejectReason() > rejectReasonInvalidMsgType && s.sessionID.BeginString == enum.BeginStringFIX42: //fix42 knows up to invalid msg type } + + if refTagID := rej.RefTagID(); refTagID != nil { + reply.Body.SetField(tagRefTagID, FIXInt(*refTagID)) + } } reply.Body.SetField(tagText, FIXString(rej.Error())) @@ -475,10 +479,6 @@ func (s *session) doReject(msg Message, rej MessageRejectError) { if err := msg.Header.GetField(tagMsgType, &msgType); err == nil { reply.Body.SetField(tagRefMsgType, msgType) } - - if refTagID := rej.RefTagID(); refTagID != nil { - reply.Body.SetField(tagRefTagID, FIXInt(*refTagID)) - } } else { reply.Header.SetField(tagMsgType, FIXString("3"))