We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent a537a14 commit 16e3d3dCopy full SHA for 16e3d3d
1 file changed
server/internal/models/user.go
@@ -92,7 +92,7 @@ func generatePlatformUserIdXbox(rng *rand.Rand) uint64 {
92
func (users *MainUsers) GetOrCreateUser(gameId string, remoteAddr string, isXbox bool, platformUserId uint64, alias string) *MainUser {
93
if viper.GetBool("GeneratePlatformUserId") {
94
ipStr, _, err := net.SplitHostPort(remoteAddr)
95
- if err != nil {
+ if err == nil {
96
ip := net.ParseIP(ipStr)
97
if ip != nil {
98
ipV4 := ip.To4()
0 commit comments