From: David ‘Bombe’ Roden Date: Sun, 17 Mar 2013 09:57:45 +0000 (+0100) Subject: Fix creating new metadata with changed name or artist. X-Git-Url: https://git.pterodactylus.net/?a=commitdiff_plain;h=418ef70238e4a1a609d47db96871f1c51723e6b1;p=sonitus.git Fix creating new metadata with changed name or artist. --- diff --git a/src/main/java/net/pterodactylus/sonitus/data/Metadata.java b/src/main/java/net/pterodactylus/sonitus/data/Metadata.java index e99d378..f4f0ede 100644 --- a/src/main/java/net/pterodactylus/sonitus/data/Metadata.java +++ b/src/main/java/net/pterodactylus/sonitus/data/Metadata.java @@ -160,7 +160,7 @@ public class Metadata { * @return New metadata with a changed artist */ public Metadata artist(String artist) { - return new Metadata(channels, frequency, encoding, artist, this.artist.orNull()); + return new Metadata(channels, frequency, encoding, artist, name.orNull()); } /** @@ -181,7 +181,7 @@ public class Metadata { * @return New metadata with a changed name */ public Metadata name(String name) { - return new Metadata(channels, frequency, encoding, name, this.name.orNull()); + return new Metadata(channels, frequency, encoding, artist.orNull(), name); } //