saoudrizwan / Disk

Easily persist structs, images, and data on iOS
MIT License
3.1k stars 170 forks source link

Fixed retrieving files from a folder. #5

Closed iossid closed 7 years ago

iossid commented 7 years ago

Hi Saoud,

Thanks a lot for this repo, I got inspired by it at many points. I found an issue which I'd like to discuss with you. It's like this, when save more than 10 items to a folder. The retrieve methods will give those files back in order like this, 0, 1, 10, 11..., 2... So I think the best way is just sort the retrieved urls, that's what this fix does. And I also make a little change to the tests.

Please take a look at it. Happy to discuss more.

Sid

saoudrizwan commented 7 years ago

Hey @iossid thank you so much for your kind words and this fix. I changed the test a bit, but things should be working as expected now. Have a good day 😄