Browse Source

bugfix

test
Stephan Richter 3 years ago
parent
commit
aef476e384
  1. 2
      pom.xml
  2. 6
      src/main/java/de/srsoftware/widerhall/data/ListMember.java

2
pom.xml

@ -6,7 +6,7 @@
<groupId>org.example</groupId> <groupId>org.example</groupId>
<artifactId>Widerhall</artifactId> <artifactId>Widerhall</artifactId>
<version>0.2.59</version> <version>0.2.60</version>
<build> <build>
<plugins> <plugins>
<plugin> <plugin>

6
src/main/java/de/srsoftware/widerhall/data/ListMember.java

@ -69,9 +69,9 @@ public class ListMember {
} }
try { try {
if (member == null) { if (member == null) {
ListMember.create(list, moderator, ListMember.STATE_MODERATOR); ListMember.create(list, moderator, STATE_MODERATOR);
} else { } else {
member.setState((member.state | STATE_MODERATOR) ^ STATE_AWAITING_CONFIRMATION); member.setState(Util.unset(member.state|STATE_MODERATOR,STATE_AWAITING_CONFIRMATION));
} }
} catch (SQLException e) { } catch (SQLException e) {
LOG.warn("Failed to make {} a moderator of {}",moderator.email(),list.email(),e); LOG.warn("Failed to make {} a moderator of {}",moderator.email(),list.email(),e);
@ -212,7 +212,7 @@ public class ListMember {
if (member == null) { if (member == null) {
ListMember.create(list, moderator, ListMember.STATE_SUBSCRIBER); ListMember.create(list, moderator, ListMember.STATE_SUBSCRIBER);
} else { } else {
member.setState(ListMember.STATE_SUBSCRIBER); member.setState(Util.unset(member.state,STATE_MODERATOR));
} }
} catch (SQLException e) { } catch (SQLException e) {
LOG.warn("Failed to make {} a subscriber of {}",moderator.email(),list.email(),e); LOG.warn("Failed to make {} a subscriber of {}",moderator.email(),list.email(),e);

Loading…
Cancel
Save