From 57593589dfd04f8d51806e44d50d9fb654d20297 Mon Sep 17 00:00:00 2001 From: tobtoht Date: Fri, 21 May 2021 00:11:59 +0200 Subject: [PATCH] SeedDialog: Fix missing 25 word seed if lang not set --- src/dialog/seeddialog.cpp | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/src/dialog/seeddialog.cpp b/src/dialog/seeddialog.cpp index 123dcae..ca8405d 100644 --- a/src/dialog/seeddialog.cpp +++ b/src/dialog/seeddialog.cpp @@ -3,6 +3,7 @@ #include "ui_seeddialog.h" #include "seeddialog.h" +#include "constants.h" SeedDialog::SeedDialog(QSharedPointer ctx, QWidget *parent) : QDialog(parent) @@ -14,6 +15,11 @@ SeedDialog::SeedDialog(QSharedPointer ctx, QWidget *parent) ui->label_restoreHeight->setText(QString::number(m_ctx->wallet->getWalletCreationHeight())); + if (m_ctx->wallet->getSeedLanguage().isEmpty()) { + qDebug() << "No seed language set, using default"; + m_ctx->wallet->setSeedLanguage(constants::seedLanguage); + } + QString seedOffset = m_ctx->wallet->getCacheAttribute("feather.seedoffset"); QString seed_14_words = m_ctx->wallet->getCacheAttribute("feather.seed"); QString seed_25_words = m_ctx->wallet->getSeed(seedOffset);