implemented update of shares table (new permission codes)
Signed-off-by: Stephan Richter <s.richter@srsoftware.de>
This commit is contained in:
@@ -111,7 +111,7 @@ public class Poll implements Mappable {
|
||||
private HashMap<Integer,Map<Integer,Integer>> selections = new HashMap<>();
|
||||
public void count(ResultSet rs) throws SQLException {
|
||||
var optionId = rs.getInt(OPTION_ID);
|
||||
var userId = rs.getObject(USER_ID);
|
||||
var userId = rs.getObject(USER);
|
||||
var weight = rs.getInt(WEIGHT);
|
||||
var optionStats = selections.computeIfAbsent(optionId, k -> new HashMap<>());
|
||||
optionStats.compute(weight, (k, sum) -> sum == null ? 1 : sum + 1);
|
||||
|
||||
Reference in New Issue
Block a user