PCLStorage icon indicating copy to clipboard operation
PCLStorage copied to clipboard

CheckExistsAsync documentation

Open reader-man opened this issue 9 years ago • 1 comments

Hi, Thanks for the great project. the "CheckExistsAsync" function does not clearly mention that it checks for a folder relative to :

FileSystem.Current.LocalStorage

e.g.

            var rootFolder = FileSystem.Current.LocalStorage;
            var exist = await rootFolder.CheckExistsAsync("DB");

and that it will not work if i give it:

            var rootFolder = FileSystem.Current.LocalStorage;

            var dbPath = PortablePath.Combine(rootFolder.Path, "DB");

            var exist = await rootFolder.CheckExistsAsync(dbPath);

as the "dbPath" is going to have a full path.

which gives a lot of headache before discovering it, at least it did for me. Wither that, or allow the "CheckExistsAsync" to work with the passed full path if its path contained in the passed one.

reader-man avatar Jun 18 '16 20:06 reader-man

this also tripped me up. seems to be difference on different platforms from what I found

JKennedy24 avatar Aug 18 '16 11:08 JKennedy24