Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Commitc4d3dd2

Browse files
authored
chore: prevent null loading sync settings (#17430)
Nulls passed to the frontend caused a page to fail to load.`Record<string,string>` can be `nil` in golang
1 parentd20966d commitc4d3dd2

File tree

3 files changed

+9
-0
lines changed

3 files changed

+9
-0
lines changed

‎coderd/idpsync/group.go

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -268,6 +268,9 @@ func (s *GroupSyncSettings) Set(v string) error {
268268
}
269269

270270
func (s*GroupSyncSettings)String()string {
271+
ifs.Mapping==nil {
272+
s.Mapping=make(map[string][]uuid.UUID)
273+
}
271274
returnruntimeconfig.JSONString(s)
272275
}
273276

‎coderd/idpsync/organization.go

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -217,6 +217,9 @@ func (s *OrganizationSyncSettings) Set(v string) error {
217217
}
218218

219219
func (s*OrganizationSyncSettings)String()string {
220+
ifs.Mapping==nil {
221+
s.Mapping=make(map[string][]uuid.UUID)
222+
}
220223
returnruntimeconfig.JSONString(s)
221224
}
222225

‎coderd/idpsync/role.go

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -286,5 +286,8 @@ func (s *RoleSyncSettings) Set(v string) error {
286286
}
287287

288288
func (s*RoleSyncSettings)String()string {
289+
ifs.Mapping==nil {
290+
s.Mapping=make(map[string][]string)
291+
}
289292
returnruntimeconfig.JSONString(s)
290293
}

0 commit comments

Comments
 (0)

[8]ページ先頭

©2009-2025 Movatter.jp