Skip to content

Commit 819c4e3

Browse files
committed
fix: never choose 'unknown' host as default for category builder
1 parent fcbd586 commit 819c4e3

File tree

1 file changed

+6
-1
lines changed

1 file changed

+6
-1
lines changed

src/views/settings/CategoryBuilder.vue

+6-1
Original file line numberDiff line numberDiff line change
@@ -192,7 +192,12 @@ export default {
192192
this.loading = true;
193193
if (!this.queryOptions.hostname) {
194194
// FIXME: This is a hack to ensure that the hostname is set (otherwise isn't due to some race condition)
195-
this.queryOptions.hostname = useBucketsStore().hosts[0];
195+
// Don't ever return the "unknown" hostname
196+
// TODO: ideally, only choose a hostname that has the right buckets
197+
this.queryOptions.hostname = _.filter(
198+
useBucketsStore().hosts,
199+
host => host !== 'unknown'
200+
)[0];
196201
}
197202
await this.categoryStore.load();
198203
const awclient = getClient();

0 commit comments

Comments
 (0)