aboutsummaryrefslogtreecommitdiff
path: root/src/github/daneren2005
diff options
context:
space:
mode:
authorScott Jackson <daneren2005@gmail.com>2014-09-19 13:42:26 -0700
committerScott Jackson <daneren2005@gmail.com>2014-09-19 13:42:26 -0700
commit384b9bafeb3077cf84789e787203620591f85587 (patch)
treef894299262158d40f5a5af8e692255489f77a177 /src/github/daneren2005
parentc040b8bdf7bb4df8bbaf5d41887e4f5a98dbbe1c (diff)
downloaddsub-384b9bafeb3077cf84789e787203620591f85587.tar.gz
dsub-384b9bafeb3077cf84789e787203620591f85587.tar.bz2
dsub-384b9bafeb3077cf84789e787203620591f85587.zip
#388 Don't scrobble songs less then 30 seconds long
Diffstat (limited to 'src/github/daneren2005')
-rw-r--r--src/github/daneren2005/dsub/service/Scrobbler.java5
1 files changed, 5 insertions, 0 deletions
diff --git a/src/github/daneren2005/dsub/service/Scrobbler.java b/src/github/daneren2005/dsub/service/Scrobbler.java
index 9958ff9e..0be11127 100644
--- a/src/github/daneren2005/dsub/service/Scrobbler.java
+++ b/src/github/daneren2005/dsub/service/Scrobbler.java
@@ -34,6 +34,11 @@ public class Scrobbler {
if(song.getSong() instanceof PodcastEpisode) {
return;
}
+
+ // Ignore songs which are under 30 seconds per Last.FM guidelines
+ if(song.getDuration() != null && song.getDuration() > 0 && song.getDuration < 30) {
+ return;
+ }
final String id = song.getSong().getId();