aboutsummaryrefslogtreecommitdiff
path: root/app/src/main/java
diff options
context:
space:
mode:
Diffstat (limited to 'app/src/main/java')
-rw-r--r--app/src/main/java/app/passwordstore/data/repo/PasswordRepository.kt2
-rw-r--r--app/src/main/java/app/passwordstore/ui/git/config/GitConfigActivity.kt2
2 files changed, 2 insertions, 2 deletions
diff --git a/app/src/main/java/app/passwordstore/data/repo/PasswordRepository.kt b/app/src/main/java/app/passwordstore/data/repo/PasswordRepository.kt
index 454054cf..39c6b384 100644
--- a/app/src/main/java/app/passwordstore/data/repo/PasswordRepository.kt
+++ b/app/src/main/java/app/passwordstore/data/repo/PasswordRepository.kt
@@ -133,7 +133,7 @@ object PasswordRepository {
/** Get the currently checked out branch. */
fun getCurrentBranch(): String? {
val repository = repository ?: return null
- val headRef = repository.getRef(Constants.HEAD) ?: return null
+ val headRef = repository.findRef(Constants.HEAD) ?: return null
return if (headRef.isSymbolic) {
val branchName = headRef.target.name
Repository.shortenRefName(branchName)
diff --git a/app/src/main/java/app/passwordstore/ui/git/config/GitConfigActivity.kt b/app/src/main/java/app/passwordstore/ui/git/config/GitConfigActivity.kt
index 1411389f..d7584e69 100644
--- a/app/src/main/java/app/passwordstore/ui/git/config/GitConfigActivity.kt
+++ b/app/src/main/java/app/passwordstore/ui/git/config/GitConfigActivity.kt
@@ -158,7 +158,7 @@ class GitConfigActivity : BaseGitActivity() {
*/
private fun headStatusMsg(repo: Repository): String {
return runCatching {
- val headRef = repo.getRef(Constants.HEAD)
+ val headRef = repo.findRef(Constants.HEAD)
if (headRef.isSymbolic) {
val branchName = headRef.target.name
val shortBranchName = Repository.shortenRefName(branchName)