mirror of
https://github.com/RetroShare/RetroShare.git
synced 2025-02-18 05:44:14 -05:00
Save persistently that default identity is created
In 943a4213fbba409d930e1542ef895264c6a79bb2 default identity creation burst has been solved but some times the duplication happens in sequent instances of the app, now te app store permanently if default identity has been created so this other kind of duplication is avoided too (hopefully)
This commit is contained in:
parent
e83fec8d84
commit
30bb84c4a9
@ -20,6 +20,7 @@ import QtQuick 2.7
|
||||
import QtQuick.Controls 2.0
|
||||
import org.retroshare.qml_components.LibresapiLocalClient 1.0
|
||||
import "." //Needed for TokensManager singleton
|
||||
import Qt.labs.settings 1.0
|
||||
|
||||
Item
|
||||
{
|
||||
@ -63,7 +64,6 @@ Item
|
||||
rsApi.request("/identity/*/", "", refreshContactsCallback)
|
||||
}
|
||||
|
||||
property bool _refreshOwnCallback_creating: false
|
||||
function refreshOwnCallback(par)
|
||||
{
|
||||
console.log("contactsView.refreshOwnCallback(par)", visible)
|
||||
@ -76,10 +76,10 @@ Item
|
||||
contactsView.own_gxs_id = json.data[0].gxs_id
|
||||
contactsView.own_nick = json.data[0].name
|
||||
}
|
||||
else if (!_refreshOwnCallback_creating)
|
||||
else if (!settings.defaultIdentityCreated)
|
||||
{
|
||||
console.log("refreshOwnCallback(par)", "creating new identity" )
|
||||
_refreshOwnCallback_creating = true
|
||||
settings.defaultIdentityCreated = true
|
||||
|
||||
var jsonData = { "name": mainWindow.pgp_name, "pgp_linked": false }
|
||||
rsApi.request(
|
||||
@ -203,4 +203,12 @@ Item
|
||||
"</pre>"
|
||||
}
|
||||
}
|
||||
|
||||
Settings
|
||||
{
|
||||
id: settings
|
||||
category: "contactsView"
|
||||
|
||||
property bool defaultIdentityCreated: false
|
||||
}
|
||||
}
|
||||
|
Loading…
x
Reference in New Issue
Block a user