mirror of https://github.com/OpenVidu/openvidu.git
openvidu-server: fix NullPointer when location is null in Participant
parent
23eed95937
commit
b9fa01eccb
|
@ -314,8 +314,8 @@ public class Participant {
|
||||||
json.addProperty("sessionId", this.sessionId);
|
json.addProperty("sessionId", this.sessionId);
|
||||||
json.addProperty("createdAt", this.token.getCreatedAt());
|
json.addProperty("createdAt", this.token.getCreatedAt());
|
||||||
json.addProperty("activeAt", this.activeAt);
|
json.addProperty("activeAt", this.activeAt);
|
||||||
json.addProperty("location", this.location.toString());
|
json.addProperty("location", this.location != null ? this.location.toString() : "unknown");
|
||||||
json.addProperty("ip", this.location.getIp());
|
json.addProperty("ip", this.location != null ? this.location.getIp() : null);
|
||||||
json.addProperty("platform", this.platform);
|
json.addProperty("platform", this.platform);
|
||||||
if (this.token.getToken() != null) {
|
if (this.token.getToken() != null) {
|
||||||
json.addProperty("token", this.token.getToken());
|
json.addProperty("token", this.token.getToken());
|
||||||
|
|
Loading…
Reference in New Issue