Code cleanup

Signed-off-by: Tomaz Canabrava <tomaz.canabrava@intel.com>
Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
This commit is contained in:
Tomaz Canabrava 2015-09-23 16:56:38 -03:00 committed by Dirk Hohndel
parent 1e88982d6f
commit ffae64ded7

View file

@ -866,10 +866,8 @@ void MainTab::updateDiveSite(int divenr)
}
uint32_t pickedUuid = ui.location->currDiveSiteUuid();
const QString newName = displayed_dive_site.name;
const uint32_t origUuid = cd->dive_site_uuid;
struct dive_site *origDs = get_dive_site_by_uuid(origUuid);
const QString origName = origDs ? origDs->name : "";
if (pickedUuid == RECENTLY_ADDED_DIVESITE) {
pickedUuid = create_dive_site(ui.location->text().isEmpty() ? qPrintable(tr("New dive site")) : qPrintable(ui.location->text()), displayed_dive.when);