From 6306081e81de727dbf51cda343677358ce85e0c6 Mon Sep 17 00:00:00 2001 From: =?utf8?q?David=20=E2=80=98Bombe=E2=80=99=20Roden?= Date: Sat, 16 Oct 2010 11:48:43 +0200 Subject: [PATCH] Copying a null profile results in an empty profile. --- src/main/java/net/pterodactylus/sone/data/Profile.java | 3 +++ 1 file changed, 3 insertions(+) diff --git a/src/main/java/net/pterodactylus/sone/data/Profile.java b/src/main/java/net/pterodactylus/sone/data/Profile.java index 242c96e..7662eda 100644 --- a/src/main/java/net/pterodactylus/sone/data/Profile.java +++ b/src/main/java/net/pterodactylus/sone/data/Profile.java @@ -51,6 +51,9 @@ public class Profile { * The profile to copy */ public Profile(Profile profile) { + if (profile == null) { + return; + } this.firstName = profile.firstName; this.middleName = profile.middleName; this.lastName = profile.lastName; -- 2.7.4