You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@cordova.apache.org by GitBox <gi...@apache.org> on 2018/12/19 16:04:19 UTC

[GitHub] klodha edited a comment on issue #306: ImagePicker returning same image

klodha edited a comment on issue #306: ImagePicker returning same image
URL: https://github.com/apache/cordova-plugin-camera/pull/306#issuecomment-448645046
 
 
   Hi. I can confirm that this works. I have an application in App Store which is using this change. And since then tried this in 2 other apps including the most recent one, and this fix seems to be working fine for me. 
   
   Mainly the change I made in this PR is generating unique file name for temporary file using the timestamps. That way web view can't cache it for each new image. With the original approach, it was using an integer starting from 1, and in each session it was creating same file name as last one. Web views got confused perhaps and thought we are requesting same file and started returning from the cache. That was the origin and alternate was making each url unique, and using a timestamp sound like a good option to me. As any camera action would take enough time to ensure that we get different value. 
   
   Hope this helps. 

----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on GitHub and use the
URL above to go to the specific comment.
 
For queries about this service, please contact Infrastructure at:
users@infra.apache.org


With regards,
Apache Git Services

---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@cordova.apache.org
For additional commands, e-mail: commits-help@cordova.apache.org