mpc 0.9.1 → 0.9.2
Sign up to get free protection for your applications and to get access to all the features.
- data/lib/mpc.rb +1 -0
- data/lib/mpc/song.rb +11 -9
- data/lib/mpc/version.rb +1 -1
- metadata +1 -1
data/lib/mpc.rb
CHANGED
data/lib/mpc/song.rb
CHANGED
@@ -1,14 +1,16 @@
|
|
1
|
-
class Mpc
|
1
|
+
class Mpc
|
2
|
+
class Song
|
2
3
|
|
3
|
-
|
4
|
-
|
5
|
-
|
4
|
+
def initialize(options)
|
5
|
+
@options = options
|
6
|
+
end
|
6
7
|
|
7
|
-
|
8
|
-
|
9
|
-
|
10
|
-
|
11
|
-
|
8
|
+
def to_s
|
9
|
+
if @options[:Artist].empty? || @options[:Title].empty?
|
10
|
+
@options[:file]
|
11
|
+
else
|
12
|
+
"#{@options[:Artist]} - #{@options[:Title]}"
|
13
|
+
end
|
12
14
|
end
|
13
15
|
end
|
14
16
|
end
|
data/lib/mpc/version.rb
CHANGED