[ 
https://issues.apache.org/jira/browse/BEANUTILS-472?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Mehdi Afsari updated BEANUTILS-472:
-----------------------------------
    Description: 
inside AbstractConverter.convert when convertArray method get called, if the 
object is an object array, only the first element of that array will return 
because of this block of code :
return Array.get(value, 0)

this willl leads data loss when the user is trying to convert an object array 
so the better solution is to throw an exception that maybe this method does not 
support object array or find a way to perform the convertion even for an object 
array

  was:
inside AbstractConverter.convert when convertArray calls if the object is an 
array type only the first element of that array will return:
return Array.get(value, 0)

this willl leads data loss so the better solution is to throw an exception or 
perform something else ~


> AbstractConverter.convert does not work properly on Object array
> ----------------------------------------------------------------
>
>                 Key: BEANUTILS-472
>                 URL: https://issues.apache.org/jira/browse/BEANUTILS-472
>             Project: Commons BeanUtils
>          Issue Type: Bug
>          Components: Locale BeanUtils / Converters
>    Affects Versions: 1.9.2
>            Reporter: Mehdi Afsari
>            Priority: Blocker
>   Original Estimate: 1h
>  Remaining Estimate: 1h
>
> inside AbstractConverter.convert when convertArray method get called, if the 
> object is an object array, only the first element of that array will return 
> because of this block of code :
> return Array.get(value, 0)
> this willl leads data loss when the user is trying to convert an object array 
> so the better solution is to throw an exception that maybe this method does 
> not support object array or find a way to perform the convertion even for an 
> object array



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)

Reply via email to