Bazaar: Cleanups

Clean up whitespaces and coding style issues.
This commit is contained in:
Tobias Hunger
2011-02-28 15:05:40 +01:00
parent f9bb4c59dc
commit 3adb533ad7
8 changed files with 55 additions and 59 deletions

View File

@@ -60,11 +60,9 @@ QString CloneWizardPage::directoryFromRepository(const QString &repository) cons
QString repo = repository.trimmed();
if (repo.startsWith(QLatin1String("lp:")))
return repo.mid(3);
else {
const QChar slash = QLatin1Char('/');
if (repo.endsWith(slash))
repo.truncate(repo.size() - 1);
// Take the basename or the repository url
return repo.mid(repo.lastIndexOf(slash) + 1);
}
const QChar slash = QLatin1Char('/');
if (repo.endsWith(slash))
repo.truncate(repo.size() - 1);
// Take the basename or the repository url
return repo.mid(repo.lastIndexOf(slash) + 1);
}