Skip to content

Commit eb5ac70

Browse files
Merge branch 'main' into feat/1700/order-by-last-activity
Signed-off-by: Cristian Scheid <74515775+cristianscheid@users.noreply.github.com>
2 parents aa3f284 + aa20db2 commit eb5ac70

File tree

4 files changed

+108
-151
lines changed

4 files changed

+108
-151
lines changed

.github/workflows/node-test.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -60,7 +60,7 @@ jobs:
6060
run: npm run test:coverage --if-present
6161

6262
- name: Collect coverage
63-
uses: codecov/codecov-action@671740ac38dd9b0130fbe1cec585b89eea48d3de # v5.5.2
63+
uses: codecov/codecov-action@1af58845a975a7985b0beb0cbe6fbbb71a41dbad # v5.5.3
6464
with:
6565
files: ./coverage/lcov.info
6666
env:

lib/dav/davProperties.ts

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -123,6 +123,7 @@ export function getFavoritesReport(): string {
123123
* Get the SEARCH body to search for recently modified/uploaded files
124124
*
125125
* @param timestamp Oldest timestamp to include (Unix timestamp)
126+
* @param limit Maximum number of items to return
126127
* @example
127128
* ```ts
128129
* // SEARCH for recent files need a different DAV endpoint
@@ -140,7 +141,7 @@ export function getFavoritesReport(): string {
140141
* }) as ResponseDataDetailed<FileStat[]>
141142
* ```
142143
*/
143-
export function getRecentSearch(timestamp: number): string {
144+
export function getRecentSearch(timestamp: number, limit: number = 100): string {
144145
const capabilities = getCapabilities() as { dav?: { search_supports_upload_time?: boolean, search_supports_last_activity?: boolean } }
145146
const supportsUploadTime = capabilities.dav?.search_supports_upload_time
146147
const supportsLastActivity = capabilities.dav?.search_supports_last_activity
@@ -215,7 +216,7 @@ export function getRecentSearch(timestamp: number): string {
215216
</d:order>
216217
</d:orderby>
217218
<d:limit>
218-
<d:nresults>100</d:nresults>
219+
<d:nresults>${limit}</d:nresults>
219220
<ns:firstresult>0</ns:firstresult>
220221
</d:limit>
221222
</d:basicsearch>

0 commit comments

Comments
 (0)