mirror of
https://github.com/bitwarden/android.git
synced 2024-10-31 23:25:45 +03:00
use internal FilesDir for temp photo
This commit is contained in:
parent
e33b49e78c
commit
72cbdcbc8d
3 changed files with 3 additions and 3 deletions
|
@ -203,7 +203,7 @@ namespace Bit.Droid
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
// camera
|
// camera
|
||||||
var file = new Java.IO.File(GetExternalFilesDir("temp"), "camera_photo.jpg");
|
var file = new Java.IO.File(FilesDir, "temp_camera_photo.jpg");
|
||||||
uri = FileProvider.GetUriForFile(this, "com.x8bit.bitwarden.fileprovider", file);
|
uri = FileProvider.GetUriForFile(this, "com.x8bit.bitwarden.fileprovider", file);
|
||||||
fileName = $"photo_{DateTime.UtcNow.ToString("yyyyMMddHHmmss")}.jpg";
|
fileName = $"photo_{DateTime.UtcNow.ToString("yyyyMMddHHmmss")}.jpg";
|
||||||
}
|
}
|
||||||
|
|
|
@ -1,5 +1,5 @@
|
||||||
<?xml version="1.0" encoding="utf-8" ?>
|
<?xml version="1.0" encoding="utf-8" ?>
|
||||||
<paths xmlns:android="http://schemas.android.com/apk/res/android">
|
<paths xmlns:android="http://schemas.android.com/apk/res/android">
|
||||||
<cache-path name="cache" path="." />
|
<cache-path name="cache" path="." />
|
||||||
<external-path name="temp" path="Android/data/com.x8bit.bitwarden/files/temp" />
|
<files-path name="internal" path="." />
|
||||||
</paths>
|
</paths>
|
||||||
|
|
|
@ -201,7 +201,7 @@ namespace Bit.Droid.Services
|
||||||
{
|
{
|
||||||
try
|
try
|
||||||
{
|
{
|
||||||
var file = new Java.IO.File(activity.GetExternalFilesDir("temp"), "camera_photo.jpg");
|
var file = new Java.IO.File(activity.FilesDir, "temp_camera_photo.jpg");
|
||||||
if(!file.Exists())
|
if(!file.Exists())
|
||||||
{
|
{
|
||||||
file.ParentFile.Mkdirs();
|
file.ParentFile.Mkdirs();
|
||||||
|
|
Loading…
Reference in a new issue