From 154917bbd1ba7d411eee9b69199501646a50874d Mon Sep 17 00:00:00 2001 From: Bruno Cauet Date: Tue, 27 Jan 2015 12:16:40 +0100 Subject: [PATCH] Add unicode() for Distance: show the distance --- beets/autotag/hooks.py | 3 +++ 1 file changed, 3 insertions(+) diff --git a/beets/autotag/hooks.py b/beets/autotag/hooks.py index c8e068e62..12d11a0b3 100644 --- a/beets/autotag/hooks.py +++ b/beets/autotag/hooks.py @@ -361,6 +361,9 @@ class Distance(object): def __rsub__(self, other): return other - self.distance + def __unicode__(self): + return "{0:.2f}".format(self.distance) + # Behave like a dict. def __getitem__(self, key):