aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--NEWS2
-rw-r--r--src/update.c5
2 files changed, 7 insertions, 0 deletions
diff --git a/NEWS b/NEWS
index 9a8ca1b2f..8d3a37f1c 100644
--- a/NEWS
+++ b/NEWS
@@ -4,6 +4,8 @@ MPD 0.14.1 - not yet released
- id3: strip leading and trailing whitespace from ID3 tags
* audio outputs:
- jack: allocate default port names (fixes a crash)
+* update:
+ - refresh stats after update
* log: automatically append newline
* fix setenv() conflict on Solaris
* configure.ac: check for pkg-config before using it
diff --git a/src/update.c b/src/update.c
index ae079b74c..10108f0a9 100644
--- a/src/update.c
+++ b/src/update.c
@@ -32,6 +32,8 @@
#include "update.h"
#include "idle.h"
#include "conf.h"
+#include "stats.h"
+#include "dbUtils.h"
#include <glib.h>
@@ -597,6 +599,9 @@ void reap_update_task(void)
spawn_update_task(path);
} else {
progress = UPDATE_PROGRESS_IDLE;
+
+ stats.numberOfSongs = countSongsIn(NULL);
+ stats.dbPlayTime = sumSongTimesIn(NULL);
}
}