fix submitter updating
This commit is contained in:
parent
4f75639780
commit
3a7e6da442
@ -483,12 +483,8 @@ export class ViewMotion extends BaseAgendaViewModel implements Searchable {
|
||||
public updateUser(update: ViewUser): void {
|
||||
if (this.motion.submitters && this.motion.submitters.findIndex(user => user.user_id === update.id)) {
|
||||
const userIndex = this.submitters.findIndex(user => user.id === update.id);
|
||||
if (userIndex < 0) {
|
||||
this.submitters.push(update);
|
||||
} else {
|
||||
this.submitters[userIndex] = update;
|
||||
}
|
||||
}
|
||||
if (this.motion.supporters_id && this.motion.supporters_id.includes(update.id)) {
|
||||
const userIndex = this.supporters.findIndex(user => user.id === update.id);
|
||||
if (userIndex < 0) {
|
||||
|
Loading…
Reference in New Issue
Block a user