扫描音乐前清空数据库,以防止重复
This commit is contained in:
parent
a21a875261
commit
7b533bb0df
@ -61,10 +61,11 @@ public class MusicToolsServiceImpl implements IMusicToolsService {
|
||||
new Thread(() -> {
|
||||
long startTime = System.currentTimeMillis();
|
||||
QQBotManager.getInstance().sendMessage("开始扫描音乐夹");
|
||||
musicDataDao.truncate();
|
||||
isScan = true;
|
||||
scan(new File(musicPath));
|
||||
isScan = false;
|
||||
com.yutou.nas.utils.Log.i("扫描完成");
|
||||
Log.i("扫描完成");
|
||||
QQBotManager.getInstance().sendMessage("音乐扫描完成,共" + getLength() + "首歌,耗时:"
|
||||
+ (System.currentTimeMillis() - startTime));
|
||||
}).start();
|
||||
|
Loading…
Reference in New Issue
Block a user