fix renumbering for last shot

main
Pullusb 2021-09-15 10:34:35 +02:00
parent ac7de45311
commit 89f48d90f9
1 changed files with 3 additions and 1 deletions

4
fn.py
View File

@ -414,11 +414,13 @@ def renumber_keep_existing(fo, offset=10):
print('-->', idx, fs.path)
if idx == last_idx: # handle last
print('last >>', fs.path)
print(ct)
if idx > 0:
prev = fsl[idx-1]
num = get_num(prev)
if num is not None:
break
add_fileslot_number(fs, num + offset)
else:
add_fileslot_number(fs, ct)
else: