cffile: inconsistent behavior of the attribute nameConflict with "makeunique" value

Description

According to the docs, this code should create a new file (nameconflict=“makeunique”), but doesn’t happen.

<cffile action="write" file="#ExpandPath('./fileExists.txt')#" output="fileExists.txt" nameconflict="makeunique">

ACF ignores completely the nameconflict attribute with "write" action.
Simple, it overwrites the file…

In Lucee:
nameconflict=“error” -> works
nameconflict=“skip” -> works
nameconflict=“overwrite” -> works
nameconflict=“makeunique” -> NOT works

Environment

None

Activity

Show:

Pothys - MitrahSoft 17 December 2020 at 13:46

I've added a test case for this ticket in the same branch.

Pull request: https://github.com/lucee/Lucee/pull/943

Zac Spitzer 30 April 2020 at 11:57

Pothys - MitrahSoft 30 April 2020 at 11:40

I've added a fix for this ticket.

Pull request: https://github.com/lucee/Lucee/pull/943

Fixed

Details

Assignee

Reporter

Priority

Fix versions

New Issue warning screen

Before you create a new Issue, please post to the mailing list first https://dev.lucee.org

Once the issue has been verified, one of the Lucee team will ask you to file an issue

Sprint

Affects versions

Created 29 April 2020 at 18:39
Updated 27 April 2022 at 16:53
Resolved 2 June 2021 at 15:22

Flag notifications