Browse Source

fix: folder redirect after creation

Torkel Ödegaard 7 years ago
parent
commit
39238c192d
1 changed files with 2 additions and 1 deletions
  1. 2 1
      public/app/features/dashboard/create_folder_ctrl.ts

+ 2 - 1
public/app/features/dashboard/create_folder_ctrl.ts

@@ -1,4 +1,5 @@
 import appEvents from 'app/core/app_events';
+import locationUtil from 'app/core/utils/location_util';
 
 export class CreateFolderCtrl {
   title = '';
@@ -19,7 +20,7 @@ export class CreateFolderCtrl {
 
     return this.backendSrv.createDashboardFolder(this.title).then(result => {
       appEvents.emit('alert-success', ['Folder Created', 'OK']);
-      this.$location.url(result.meta.url);
+      this.$location.url(locationUtil.stripBaseFromUrl(result.meta.url));
     });
   }