Assets flagged as duplicate from another folder

I have…

  • [x] Checked the logs and have uploaded a log file and provided a link because I found something suspicious there. Please do not post the log file in the topic because very often something important is missing.

I’m submitting a…

  • [ ] Regression (a behavior that stopped working in a new release)
  • [ x] Bug report
  • [ ] Performance issue
  • [ ] Documentation issue or request

Current behavior

When uploading a file that shares a file name with another file in another assets folder, the file is flagged as a duplicate and not uploaded.

Expected behavior

I expected that files are only treated as duplicates when in the same folder.

Minimal reproduction of the problem

1 ) create two asset folders
2 ) upload the same asset ( or two with the same filename ) into both folders
3 ) see ‘duplicate asset’ failure

Environment

  • [ x] Self hosted with docker
  • [ ] Self hosted with IIS
  • [ ] Self hosted with other version
  • [ ] Cloud version

Version: squidex/squidex:latest

Browser:

  • [ x] Chrome (desktop)
  • [ ] Chrome (Android)
  • [ ] Chrome (iOS)
  • [ ] Firefox
  • [ ] Safari (desktop)
  • [ ] Safari (iOS)
  • [ ] IE
  • [ ] Edge

Hi Steven,

than you for your 2 bug reports.

This is by design right now, because very often the files are just badly organized. BUT it is only a flag in the API, so I can probably enhance the UI to upload the file anyway.

Like with an extra confirm dialog or so.

That would be helpful

I was also thinking this might also be a project level setting, then have a toggle in the UI to ‘always apply’ when prompted during an upload perhaps?

What exactly? To turn on or off this feature or to make the check per folder?

sure, let me expand on my idea:

in the project settings, we could have an checkbox option that says :

[ ] duplicate assets: True to duplicate the asset, event if the file has been uploaded. ( btw - this line was copied from the docs, notice the typeo in “event” )

In the UI, when uploading a potential duplicate it can then ask if this is enables in the settings, and if so do not show and modal and allow the upload.

If this is not set, show the modal that says:

Duplicate asset found. Continue?
[ yes ] [ no ]
[  ] Always apply

if the user chooses ‘always apply’, it would update the project setting mentioned earlier

All confirm dialogs have a remember button anyway, so you would get this behavior as well.

1 Like