Interfaces/zugferd: fix parameter error which leads to falsely allowing mails with two zugferd invoices
This commit is contained in:
parent
a9567a9d18
commit
79cad24b3f
@ -220,7 +220,7 @@ Public Class ZUGFeRDInterface
|
|||||||
Try
|
Try
|
||||||
Dim oNavigator As XPathNavigator = pDocument.Item2.CreateNavigator()
|
Dim oNavigator As XPathNavigator = pDocument.Item2.CreateNavigator()
|
||||||
Dim oReader As XmlReader
|
Dim oReader As XmlReader
|
||||||
Dim oResult = Nothing
|
Dim oObject As Object = Nothing
|
||||||
|
|
||||||
Dim oAllowedTypes As New List(Of Type)
|
Dim oAllowedTypes As New List(Of Type)
|
||||||
|
|
||||||
@ -242,7 +242,7 @@ Public Class ZUGFeRDInterface
|
|||||||
|
|
||||||
Try
|
Try
|
||||||
oReader = oNavigator.ReadSubtree()
|
oReader = oNavigator.ReadSubtree()
|
||||||
oResult = oSerializer.Deserialize(oReader)
|
oObject = oSerializer.Deserialize(oReader)
|
||||||
_logger.Debug("Serializing with type [{0}] succeeded", oType.FullName)
|
_logger.Debug("Serializing with type [{0}] succeeded", oType.FullName)
|
||||||
Exit For
|
Exit For
|
||||||
Catch ex As Exception
|
Catch ex As Exception
|
||||||
@ -252,11 +252,11 @@ Public Class ZUGFeRDInterface
|
|||||||
End Try
|
End Try
|
||||||
Next
|
Next
|
||||||
|
|
||||||
If oResult Is Nothing Then
|
If oObject Is Nothing Then
|
||||||
Throw New ApplicationException("No Types matched the given document. Document could not be serialized.")
|
Throw New ApplicationException("No Types matched the given document. Document could not be serialized.")
|
||||||
End If
|
End If
|
||||||
|
|
||||||
Return oResult
|
Return New Tuple(Of String, Object)(pDocument.Item1, oObject)
|
||||||
|
|
||||||
Catch ex As Exception
|
Catch ex As Exception
|
||||||
_logger.Error(ex)
|
_logger.Error(ex)
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user