remove 'as'

This commit is contained in:
Lone Iversen
2022-11-21 11:08:41 +01:00
parent 61940205d8
commit c572470f8f
3 changed files with 4 additions and 4 deletions

View File

@@ -95,7 +95,7 @@ export class UmbDashboardExamineIndexElement extends UmbContextConsumerMixin(Lit
private async _getIndexData() {
try {
const index = await SearchResource.getSearchIndexByIndexName({ indexName: this.indexName });
this._indexData = index as Index;
this._indexData = index;
} catch (e) {
if (e instanceof ApiError) {
const error = e as ProblemDetails;

View File

@@ -66,7 +66,7 @@ export class UmbDashboardExamineOverviewElement extends UmbContextConsumerMixin(
private async _getIndexers() {
try {
const indexers = await SearchResource.getSearchIndex({ take: 9999, skip: 0 });
this._indexers = indexers.items as Index[];
this._indexers = indexers.items;
} catch (e) {
if (e instanceof ApiError) {
const error = e as ProblemDetails;
@@ -79,7 +79,7 @@ export class UmbDashboardExamineOverviewElement extends UmbContextConsumerMixin(
private async _getSearchers() {
try {
const searchers = await SearchResource.getSearchSearcher({ take: 9999, skip: 0 });
this._searchers = searchers.items as Searcher[];
this._searchers = searchers.items;
} catch (e) {
if (e instanceof ApiError) {
const error = e as ProblemDetails;

View File

@@ -144,7 +144,7 @@ export class UmbDashboardExamineSearcherElement extends UmbContextConsumerMixin(
take: 9999,
skip: 0,
});
this._searchResults = res.items as SearchResult[];
this._searchResults = res.items;
this._updateFieldFilter();
} catch (e) {
if (e instanceof ApiError) {