cloud-py-api/nc_py_api

Missing files.find() method usage, docs, examples, bug when searching by "name"

Closed this issue · 0 comments

Discussed in #86

Originally posted by CooperGerman August 17, 2023
Hi,
I'm currently trying to implement some of the features of this package and i am facing some issues regarding the files.find() method.
I can't seem to properly use it and while debugging i found some code which i'm not very sure about in file nc_py_api/files/files.py lines 46-53.

SEARCH_PROPERTIES_MAP = {
    "name:": "d:displayname",  # like, eq
    "mime": "d:getcontenttype",  # like, eq
    "last_modified": "d:getlastmodified",  # gt, eq, lt
    "size": "oc:size",  # gt, gte, eq, lt
    "favorite": "oc:favorite",  # eq
    "fileid": "oc:fileid",  # eq
}

For entry "name" should there be the colon inside the string ?

Thanks in advance for any help, i would really appreciate an example of this method allowing to verify if a file exists in a folder.