Skip to content

Commit

Permalink
Merge pull request #2267 from spenceralger/allow_settings_without_def…
Browse files Browse the repository at this point in the history
…ault_index_pattern

LGTM Allow navigating throughout settings without having a default index pattern
  • Loading branch information
rashidkpc committed Dec 12, 2014
2 parents 728863a + 5a14b98 commit 03e38a1
Showing 1 changed file with 2 additions and 5 deletions.
7 changes: 2 additions & 5 deletions src/kibana/utils/routes/_setup.js
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,7 @@ define(function (require) {
var firstNoDefaultError = true;

var rootSearchSource = Private(require('components/courier/data_source/_root_search_source'));
var allowedRoutesRE = /^\/settings\//;

return {
routeSetupWork: function () {
Expand All @@ -17,11 +18,7 @@ define(function (require) {
])
.then(function () {
var path = $route.current.$$route.originalPath;
var allowedRoutes = [
'/settings/indices/',
'/settings/about'
];
if (allowedRoutes.indexOf(path) < 0) {
if (!path.match(allowedRoutesRE)) {
return courier.indexPatterns.getIds()
.then(function (patterns) {
if (!config.get('defaultIndex')) {
Expand Down

0 comments on commit 03e38a1

Please sign in to comment.