mirror of
https://github.com/subsurface/subsurface.git
synced 2025-01-31 23:13:25 +00:00
Mobile: remove useless attempt to prevent access to the cloud
This code really made no sense, adding a comment to try to explain that. Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
This commit is contained in:
parent
4111de70e8
commit
08e2013d1e
1 changed files with 3 additions and 3 deletions
|
@ -280,10 +280,10 @@ void QMLManager::openLocalThenRemote(QString url)
|
||||||
DiveListModel::instance()->clear();
|
DiveListModel::instance()->clear();
|
||||||
setNotificationText(tr("Open local dive data file"));
|
setNotificationText(tr("Open local dive data file"));
|
||||||
QByteArray fileNamePrt = QFile::encodeName(url);
|
QByteArray fileNamePrt = QFile::encodeName(url);
|
||||||
bool glo = git_local_only;
|
/* if this is a cloud storage repo and we have no local cache (i.e., it's the first time
|
||||||
git_local_only = true;
|
* we try to open this), parse_file will ALWAYS connect to the remote and populate the cache.
|
||||||
|
* Otherwise parse_file will respect the git_local_only flag and only update if that isn't set */
|
||||||
int error = parse_file(fileNamePrt.data(), &dive_table, &trip_table, &dive_site_table);
|
int error = parse_file(fileNamePrt.data(), &dive_table, &trip_table, &dive_site_table);
|
||||||
git_local_only = glo;
|
|
||||||
if (error) {
|
if (error) {
|
||||||
appendTextToLog(QStringLiteral("loading dives from cache failed %1").arg(error));
|
appendTextToLog(QStringLiteral("loading dives from cache failed %1").arg(error));
|
||||||
setNotificationText(tr("Opening local data file failed"));
|
setNotificationText(tr("Opening local data file failed"));
|
||||||
|
|
Loading…
Add table
Reference in a new issue