I propose that
love.filesystem.exists be removed because...
- It's redundant.
- It's not very useful.
- It's frequently misused.
love.filesystem.exists('item') is a shortcut for
love.filesystem.isFile('item') or love.filesystem.isDirectory('item'). I don't think it's worth having though. There is a single use I can think of for having it, which is for when you want to save a file or make a directory, but you don't want to overwrite anything, so you check if something with that name exists. I don't think this use case is common enough that the shortcut is needed.
love.filesystem.isFile('item') or love.filesystem.isDirectory('item') is actually quite elegant I think, much like
ParticleSystem:getCount() == ParticleSystem:getBufferSize() as opposed to
ParticleSystem:isFull(). In both cases, redundancy is avoided, and the potential but somewhat uncommon needs for finding whether anything with a name exists or if a ParticleSystem is full is possible by using the functions available.
It's also misused. Just then I grepped some projects, and it appeared a few times, but in all the places it was found it would have made more sense to use
isDirectory, lest the game try to open a directory as a file, or treat a file as a directory.
There's also the minor aesthetic issue which is that it returns a single boolean value but its name doesn't start with "is" or "has".