Skip to content

Folder "Keep both" overwrites the existing folder when its name contains ( ) + or . #3655

Closed

Description

@AlexAndBear

Initial Checklist

  • I understand this is a bug report and questions should be posted in the Community Discussions
  • I searched issues and couldn’t find anything (or linked relevant results below)

Bug Description

Folder "Keep both" overwrites the existing folder when its name contains ( ) + or .. Cause: packages/web-app-files/src/helpers/resource/actions/upload.ts:190,194,198,205,211 build new RegExp(/${folder}) from the raw folder name, so (, ), + and . act as regex syntax and the paths are not rewritten.

Reproduction Steps

  1. A folder report (final) contains in.txt ("S").
  2. Upload (drop) a local folder report (final) containing in.txt ("L").
  3. Choose "Keep both".

Expected Outcome

A new folder report (final) (1) is created.

Actual Outcome

MKCOL report (final) returns 405 and report (final)/in.txt is overwritten with "L". The panel says "0 items uploaded".

Screenshot

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

Labels

Type

No type

Projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions