fixed BUG-27, duplicate count per same named files in 2 dirs, was always 1

This commit is contained in:
2021-03-01 18:46:03 +11:00
parent 564962097a
commit 06eb1ef927
2 changed files with 1 additions and 3 deletions

1
BUGs
View File

@@ -4,4 +4,3 @@ BUG-25: file counts are wacky, now?
file_details = 7 of 3?!? file_details = 7 of 3?!?
BUG-26: when choosing between duplicate dirs to keep, the radio buytton is not unique per directory, so if you have 10 sets of dirs, only the bottom one has a green option BUG-26: when choosing between duplicate dirs to keep, the radio buytton is not unique per directory, so if you have 10 sets of dirs, only the bottom one has a green option
BUG-27: I believe count of duplicate files per directory (is 1 each time), is incorrect (see 20150830-alana-lesl*)

View File

@@ -276,8 +276,8 @@ def fix_dups():
# (MOST COMMON, and I think we dont care per file, just per path) # (MOST COMMON, and I think we dont care per file, just per path)
elif d1 != dups[hash][0]['d']: elif d1 != dups[hash][0]['d']:
if d1 != '': if d1 != '':
dup_cnt=1
per_path_dups.append({'count': dup_cnt, 'd1': d1, 'd2': d2, 'did1': did1, 'did2': did2, 'hashes' : hashes }) per_path_dups.append({'count': dup_cnt, 'd1': d1, 'd2': d2, 'did1': did1, 'did2': did2, 'hashes' : hashes })
dup_cnt=1
d1 = dups[hash][0]['d'] d1 = dups[hash][0]['d']
d2 = dups[hash][1]['d'] d2 = dups[hash][1]['d']
did1 = dups[hash][0]['did'] did1 = dups[hash][0]['did']
@@ -290,7 +290,6 @@ def fix_dups():
if d1 != '': if d1 != '':
per_path_dups.append({'count': dup_cnt, 'd1': d1, 'd2': d2, 'did1': did1, 'did2': did2, 'hashes' : hashes }) per_path_dups.append({'count': dup_cnt, 'd1': d1, 'd2': d2, 'did1': did1, 'did2': did2, 'hashes' : hashes })
print( f"msg={request.form['fe_msg_id']}" )
return render_template("dups.html", per_file_dups=per_file_dups, per_path_dups=per_path_dups, fe_msg_id=request.form['fe_msg_id'] ) return render_template("dups.html", per_file_dups=per_file_dups, per_path_dups=per_path_dups, fe_msg_id=request.form['fe_msg_id'] )
@app.route("/rm_dups", methods=["POST"]) @app.route("/rm_dups", methods=["POST"])