Upgraded dependencies and SDK

This commit is contained in:
2024-01-07 20:21:55 +01:00
parent 8e778e8cc3
commit dce569cb99
11 changed files with 23 additions and 32 deletions

View File

@ -22,9 +22,9 @@ class CacheableFile {
CacheableFile({required this.path, required this.isDirectory, required this.name, this.mimeType, this.size, this.eTag, this.createdAt, this.modifiedAt});
CacheableFile.fromDavFile(WebDavFile file) {
path = file.path;
path = file.path.path;
isDirectory = file.isDirectory;
name = file.isDirectory ? file.name : file.path.split("/").last;
name = file.isDirectory ? file.name : file.path.path.split("/").last;
mimeType = file.mimeType;
size = file.size;
eTag = file.etag;

View File

@ -14,7 +14,7 @@ class ListFiles extends WebdavApi<ListFilesParams> {
@override
Future<ListFilesResponse> run() async {
List<WebDavFile> davFiles = (await (await WebdavApi.webdav).propfind(Uri.parse(params.path))).toWebDavFiles();
List<WebDavFile> davFiles = (await (await WebdavApi.webdav).propfind(PathUri.parse(params.path))).toWebDavFiles();
Set<CacheableFile> files = davFiles.map((e) => CacheableFile.fromDavFile(e)).toSet();
// webdav handles subdirectories wrong, this is a fix