CommunityScripts icon indicating copy to clipboard operation
CommunityScripts copied to clipboard

[renamerOnUpdate] Bug when only changing letter case in filename

Open echo6ix opened this issue 2 years ago • 0 comments

Bug

If the config is set up in a way where the script attempts to only rename the letter case in a filename, the script thinks there is a collision with a duplicate filename, issues a warning, and renames the file while appending _1 to the filename

Expected behavior

The script should detect that there is no existing collision with a duplicate filename and proceed to rename the file with the appropriate letter case changes

Steps to reproduce

Change the config to only alter the letter case of a filename. For example:

field_replacer = {
    "$title": {"replace": "The", "with": "THE"}
}

Current workaround

To undo the _n addition to files, it's as simple as re-running the rename task on the file. It will not detect a duplicate the second time and rename it correctly.

echo6ix avatar Sep 12 '23 04:09 echo6ix