Skip to content

Commit

Permalink
Fixed the self-sign row creation for onfloor freshmen during sync
Browse files Browse the repository at this point in the history
  • Loading branch information
JoelEager committed Sep 3, 2018
1 parent 0e0f292 commit 614c127
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion packet/commands.py
Original file line number Diff line number Diff line change
@@ -71,7 +71,9 @@ def sync_freshmen(freshmen_csv):
# pylint: disable=cell-var-from-loop
current_fresh_sigs = set(map(lambda fresh_sig: fresh_sig.freshman_username, packet.fresh_signatures))
for csv_freshman in filter(lambda csv_freshman: csv_freshman.rit_username not in current_fresh_sigs and
csv_freshman.onfloor, freshmen_in_csv.values()):
csv_freshman.onfloor and
csv_freshman.rit_username != packet.freshman_username,
freshmen_in_csv.values()):
db.session.add(FreshSignature(packet=packet, freshman=freshmen_in_db[csv_freshman.rit_username]))

db.session.commit()

0 comments on commit 614c127

Please sign in to comment.