web/admin: fix error adding users to groups (#5016)

* web/admin: fix error adding users to groups

and vice versa

Signed-off-by: Jens Langhammer <jens@goauthentik.io>

* remove seed

Signed-off-by: Jens Langhammer <jens@goauthentik.io>

---------

Signed-off-by: Jens Langhammer <jens@goauthentik.io>
This commit is contained in:
Jens L 2023-03-20 18:15:36 +01:00 committed by GitHub
parent eb78632853
commit 32840d3909
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
4 changed files with 6 additions and 5 deletions

2
go.mod
View File

@ -1,6 +1,6 @@
module goauthentik.io
go 1.18
go 1.20
require (
github.com/Netflix/go-env v0.0.0-20210215222557-e437a7e7f9fb

View File

@ -1,7 +1,6 @@
package common
import (
"math/rand"
"os"
"os/signal"
"syscall"
@ -11,7 +10,6 @@ import (
)
func Init() chan os.Signal {
rand.Seed(time.Now().UnixNano())
interrupt := make(chan os.Signal, 1)
signal.Notify(interrupt, os.Interrupt)
signal.Notify(interrupt, syscall.SIGINT)

View File

@ -2,7 +2,7 @@ import { AKElement } from "@goauthentik/elements/Base";
import { Chip } from "@goauthentik/elements/chips/Chip";
import { CSSResult, TemplateResult, css, html } from "lit";
import { customElement } from "lit/decorators.js";
import { customElement, property } from "lit/decorators.js";
import PFButton from "@patternfly/patternfly/components/Button/button.css";
import PFChip from "@patternfly/patternfly/components/Chip/chip.css";
@ -28,6 +28,9 @@ export class ChipGroup extends AKElement {
];
}
@property()
name?: string;
set value(v: (string | number | undefined)[]) {
return;
}

View File

@ -201,7 +201,7 @@ export class Form<T> extends AKElement {
json: { [key: string]: unknown },
): void {
let parent = json;
if (!element.name.includes(".")) {
if (!element.name?.includes(".")) {
parent[element.name] = value;
return;
}