mirror of
https://github.com/directus/directus.git
synced 2026-02-01 09:05:01 -05:00
Add limit options for deleteMany files (#6561)
* Changed filesize to bigint for large files * Update api/src/database/migrations/20210626A-change-filesize-bigint.ts * add `limit -1` for deleteMany files options from #6560 Co-authored-by: Rijk van Zanten <rijkvanzanten@me.com>
This commit is contained in:
committed by
rijkvanzanten
parent
6116b627f4
commit
96c7963782
@@ -190,7 +190,7 @@ export class FilesService extends ItemsService {
|
||||
* Delete multiple files
|
||||
*/
|
||||
async deleteMany(keys: PrimaryKey[], opts?: MutationOptions): Promise<PrimaryKey[]> {
|
||||
const files = await super.readMany(keys, { fields: ['id', 'storage'] });
|
||||
const files = await super.readMany(keys, { fields: ['id', 'storage'], limit: -1 });
|
||||
|
||||
if (!files) {
|
||||
throw new ForbiddenException();
|
||||
|
||||
Reference in New Issue
Block a user