aboutsummaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorScott Jackson <daneren2005@gmail.com>2013-11-12 20:08:54 -0800
committerScott Jackson <daneren2005@gmail.com>2013-11-12 20:08:54 -0800
commitcaf1b6c523eb350467ea2cb4777e9d304586bc75 (patch)
tree8110fb17767a6ff90fa533c09369d5112caa63be /src
parent5eb2b5780cb8b2669e00660af4ff1f0f46f5505a (diff)
downloaddsub-caf1b6c523eb350467ea2cb4777e9d304586bc75.tar.gz
dsub-caf1b6c523eb350467ea2cb4777e9d304586bc75.tar.bz2
dsub-caf1b6c523eb350467ea2cb4777e9d304586bc75.zip
Don't crash if context isn't there yet
Diffstat (limited to 'src')
-rw-r--r--src/github/daneren2005/dsub/fragments/DownloadFragment.java4
1 files changed, 4 insertions, 0 deletions
diff --git a/src/github/daneren2005/dsub/fragments/DownloadFragment.java b/src/github/daneren2005/dsub/fragments/DownloadFragment.java
index 6da6ca70..28679d2b 100644
--- a/src/github/daneren2005/dsub/fragments/DownloadFragment.java
+++ b/src/github/daneren2005/dsub/fragments/DownloadFragment.java
@@ -794,6 +794,10 @@ public class DownloadFragment extends SubsonicFragment implements OnGestureListe
}
private void updateButtons() {
+ if(context == null) {
+ return;
+ }
+
SharedPreferences prefs = Util.getPreferences(context);
boolean equalizerOn = prefs.getBoolean(Constants.PREFERENCES_EQUALIZER_ON, false);
if(equalizerOn && getDownloadService() != null && getDownloadService().getEqualizerController() != null &&