Closed RingoMckraken closed 4 years ago
No, Paper doesn't have the function for that. The only way to remove the old data without knowing the names for the "books" is to remove all folders in app's internal storage which has files with *.pt
extension. But as I said, Paper DB doesn't have the built-in function for that.
Thanks for the response, I have found a (somewhat hacky) way of doing it by iterating through the files directory and attempting to call Paper.book(file.name).destroy() while catching exceptions.
By the way, I love this library have been using it for years!
Given a situation where an app uses the global Paper.book() as well as some named ones, is there a way built into paper that can delete all books in one call? My situation is I've been handed a code base where the previous developer has left but there does not seem to be anyway of tracking down the different versions and keys they used to for different versions of the app.