Fix ali cache on some tv devices
This commit is contained in:
parent
4c1ee8521b
commit
07c41a8879
|
|
@ -11,12 +11,16 @@ import java.io.InputStreamReader;
|
||||||
|
|
||||||
public class FileUtil {
|
public class FileUtil {
|
||||||
|
|
||||||
public static File getCacheDir() {
|
public static File getExternalCacheDir() {
|
||||||
return Init.context().getExternalCacheDir();
|
return Init.context().getExternalCacheDir();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
public static File getCacheDir() {
|
||||||
|
return Init.context().getCacheDir();
|
||||||
|
}
|
||||||
|
|
||||||
public static File getCacheFile(String fileName) {
|
public static File getCacheFile(String fileName) {
|
||||||
return new File(getCacheDir(), fileName);
|
return getExternalCacheDir().canWrite() ? new File(getExternalCacheDir(), fileName) : new File(getCacheDir(), fileName);
|
||||||
}
|
}
|
||||||
|
|
||||||
public static void write(File file, String data) {
|
public static void write(File file, String data) {
|
||||||
|
|
|
||||||
Binary file not shown.
|
|
@ -1 +1 @@
|
||||||
ecddb20dad437ff099b1e777bc5545ab
|
5c42e2f85ec3f05bfd281e4fcf40468a
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue