Skip to content

Commit

Permalink
Empty string for username
Browse files Browse the repository at this point in the history
  • Loading branch information
jdmcd committed May 2, 2023
1 parent 689fd97 commit 911c451
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion Sources/OneRoster/Models/User.swift
Original file line number Diff line number Diff line change
Expand Up @@ -134,7 +134,7 @@ public struct User: Codable, OneRosterBase {
status = try values.decode(StatusType.self, forKey: .status)
dateLastModified = try values.decode(String.self, forKey: .dateLastModified)
metadata = try values.decodeIfPresent(Dictionary.self, forKey: .metadata)
username = try values.decode(String.self, forKey: .username)
username = (try? values.decode(String.self, forKey: .username)) ?? ""
userIds = try values.decodeIfPresent([UserId].self, forKey: .userIds) ?? []
enabledUser = try values.stringBoolean(forKey: .enabledUser)
givenName = try values.decode(String.self, forKey: .givenName)
Expand Down

0 comments on commit 911c451

Please sign in to comment.