Fix a crash when viewing statistics including a score on a course which is not found.
[scorecard] / src / main-window.cpp
index 6cd05d3..1ace27b 100644 (file)
@@ -466,7 +466,7 @@ void MainWindow::newScore()
 
         Club *club = findClub(clubName);
         if (!club) {
-            showNote(tr("Error: no such club"));
+            showNote(tr("No club"));
             return;
         }
         Course *course = club->getCourse(courseName);
@@ -503,7 +503,7 @@ void MainWindow::editScore()
         course = findCourse(score->getClubName(), score->getCourseName());
 
     if (!course || !score) {
-        qDebug() << "No score/course to edit";
+        showNote(tr("No score or course to edit"));
         return;
     }