fix: store item type & update file check

This commit is contained in:
lollipopkit
2023-10-28 19:02:54 +08:00
parent c3ca5725a4
commit 7de5987355
7 changed files with 38 additions and 29 deletions

View File

@@ -34,3 +34,6 @@ String? getFileName(String? path) {
String pathJoin(String path1, String path2) {
return path1 + (path1.endsWith('/') ? '' : '/') + path2;
}
/// Check if a url is a file url (ends with a file extension)
bool isFileUrl(String url) => url.split('/').last.contains('.');