mirror of
https://github.com/tumic0/GPXSee.git
synced 2024-12-03 16:09:08 +01:00
Fixed error handling
This commit is contained in:
parent
2002b828dd
commit
7b03c4d852
@ -17,13 +17,9 @@ bool MapList::loadMap(Map *map, const QString &path)
|
|||||||
if (map && map->isValid()) {
|
if (map && map->isValid()) {
|
||||||
_maps.append(map);
|
_maps.append(map);
|
||||||
return true;
|
return true;
|
||||||
} else if (map) {
|
|
||||||
_errorPath = path;
|
|
||||||
_errorString = map->errorString();
|
|
||||||
return false;
|
|
||||||
} else {
|
} else {
|
||||||
_errorString = path;
|
_errorPath = path;
|
||||||
_errorString = "Unknown file format";
|
_errorString = (map) ? map->errorString() : "Unknown file format";
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user