importzugferdfiles: fix conversion error
This commit is contained in:
@@ -6,18 +6,7 @@ Public Class PropertyValues
|
||||
Private Shared _indexPattern = "\((\d+)\)"
|
||||
Private Shared _indexRegex As New Regex(_indexPattern)
|
||||
|
||||
Public Shared Function GetPropValues(Obj As Object, PropertyName As String)
|
||||
Dim oResult As Object = GetPropValue(Obj, PropertyName)
|
||||
|
||||
' Wrap the result of `GetPropValue` in a list if a single Value is returned
|
||||
If TypeOf oResult Is List(Of Object) Then
|
||||
Return oResult
|
||||
Else
|
||||
Return New List(Of Object) From {oResult}
|
||||
End If
|
||||
End Function
|
||||
|
||||
Public Shared Function GetPropValue(Obj As Object, PropertyName As String)
|
||||
Public Shared Function GetPropValue(Obj As Object, PropertyName As String) As List(Of Object)
|
||||
Dim oNameParts As String() = PropertyName.Split("."c)
|
||||
|
||||
If IsNothing(Obj) Then
|
||||
@@ -78,7 +67,7 @@ Public Class PropertyValues
|
||||
End If
|
||||
Next
|
||||
|
||||
Return Obj
|
||||
Return New List(Of Object) From {Obj}
|
||||
End Function
|
||||
|
||||
Private Shared Function GetIndex(Prop As String) As Integer
|
||||
|
||||
Reference in New Issue
Block a user