mirror of
https://github.com/greenart7c3/Amber.git
synced 2026-10-06 11:28:22 +00:00
Use string resource for account import message
This commit is contained in:
@@ -8,6 +8,7 @@ import com.anggrayudi.storage.extension.toDocumentFile
|
||||
import com.anggrayudi.storage.file.openInputStream
|
||||
import com.greenart7c3.nostrsigner.Amber
|
||||
import com.greenart7c3.nostrsigner.LocalPreferences
|
||||
import com.greenart7c3.nostrsigner.R
|
||||
import com.greenart7c3.nostrsigner.models.Account
|
||||
import com.greenart7c3.nostrsigner.models.AccountExportData
|
||||
import com.vitorpamplona.quartz.nip01Core.core.toHexKey
|
||||
@@ -45,7 +46,7 @@ object AccountExportService {
|
||||
oi?.bufferedReader().use { reader ->
|
||||
reader?.readLines()?.forEachIndexed { index, line ->
|
||||
try {
|
||||
onText("Importing account ${index + 1}")
|
||||
onText(Amber.instance.getString(R.string.importing_account, index + 1))
|
||||
|
||||
val accountData = AccountExportData.fromJson(line)
|
||||
val nsec = Nip49().decrypt(accountData.nsec, password)
|
||||
|
||||
@@ -603,4 +603,5 @@
|
||||
<string name="response">Response</string>
|
||||
<string name="recover_from_bac">Recover from backup</string>
|
||||
<string name="recover_from_backup">Recover from backup</string>
|
||||
<string name="importing_account">Importing account %1$d</string>
|
||||
</resources>
|
||||
|
||||
Reference in New Issue
Block a user