I've played with the Zip object a little and I like how much it's easy to use zip archives.
But the Zip archive constructor only uses files as "strings".
For consistency with the framework, wouldn't it be better if the Zip constructor accepts File objects as well ?
It is indeed consistent. I just incorporated this change. It will be available for the next version.
Thank you for the feedback 😉
I have also noticed that the Zip constructor returns an error if the file is not a valid archive (such as a ".txt" file for example).
But the Zip object does not test the validity of an archive, and I think it would be a good idea to have it.
You are right. I think I will implement a "isvalid()" function inside the zip module.
Thanks again for your help.
Update: The function zip.isvalid() is implemented and will be available in the next release
Thanks you for considering my proposal for LuaRT 0.9.5 !
Powered by FreeFlarum.(remove this footer)