Skip to content
This repository was archived by the owner on Oct 15, 2024. It is now read-only.

Commit 51e2a43

Browse files
committed
one getWorkTree less, we should remove them all
1 parent 9082519 commit 51e2a43

File tree

1 file changed

+4
-2
lines changed

1 file changed

+4
-2
lines changed

app/src/main/java/com/zeapo/pwdstore/crypto/PgpHandler.java

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -738,8 +738,10 @@ public void onBound(IOpenPgpService2 service) {
738738
if (operation.equals("DECRYPT")) {
739739
setContentView(R.layout.decrypt_layout);
740740
((TextView) findViewById(R.id.crypto_password_file)).setText(extra.getString("NAME"));
741-
String cat = new File(extra.getString("FILE_PATH").replace(PasswordRepository.getWorkTree().getAbsolutePath(), ""))
742-
.getParentFile().getName();
741+
String path = extra
742+
.getString("FILE_PATH")
743+
.replace(PasswordRepository.getRepositoryDirectory(getApplicationContext()).getAbsolutePath(), "");
744+
String cat = new File(path).getParentFile().getName();
743745

744746
((TextView) findViewById(R.id.crypto_password_category)).setText(cat + "/");
745747
decryptAndVerify(new Intent());

0 commit comments

Comments
 (0)