diff --git a/src/app/TopNav.vue b/src/app/TopNav.vue
index 1d4f374..80b6d77 100644
--- a/src/app/TopNav.vue
+++ b/src/app/TopNav.vue
@@ -25,6 +25,9 @@
Server settings
+
+ Scan media folders
+
About
@@ -63,6 +66,9 @@
...mapActions([
'showMenu',
]),
+ scan() {
+ this.$api.scan()
+ },
logout() {
this.$auth.logout()
this.$router.go(0)
diff --git a/src/shared/api.ts b/src/shared/api.ts
index e4191f9..8c68e58 100644
--- a/src/shared/api.ts
+++ b/src/shared/api.ts
@@ -308,6 +308,10 @@ export class API {
return this.get('rest/deleteInternetRadioStation', { id })
}
+ async scan(): Promise {
+ return this.get('rest/startScan')
+ }
+
private normalizeRadioStation(item: any): Track & RadioStation {
return {
id: `radio-${item.id}`,