Fix for Android temp directory.
[clinton/xbmc-groove.git] / resources / lib / GroovesharkAPI.py
index 9376956..21e2bc1 100644 (file)
@@ -42,14 +42,14 @@ class GrooveAPI:
        _debugging = False
 
        # Constructor
-       def __init__(self, debug):
+       def __init__(self, debug, tempDir):
                
                self._debugging = debug
                self.simplejson = simplejson
                if "linux" in sys.platform.lower():
                        socket.setdefaulttimeout(30)
                        
-               self.cacheDir = os.path.join(tempfile.gettempdir(),getpass.getuser() + '_' + 'groovesharkapi')
+               self.cacheDir = tempDir
                if os.path.isdir(self.cacheDir) == False:
                        os.makedirs(self.cacheDir)
                        if self._debugging: