Skip to content

Commit

Permalink
fix(annotations): fix type errors that prevent running bootstrap and …
Browse files Browse the repository at this point in the history
…tests

after updating to rest-js v1.6.0, a few types had changed causing TS compile errors

AFFECTS PACKAGES:
@esri/hub-annotations

ISSUES CLOSED: #47
  • Loading branch information
tomwayson authored and jgravois committed Aug 7, 2018
1 parent 526950c commit 301412f
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 3 deletions.
5 changes: 3 additions & 2 deletions packages/annotations/src/search.ts
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,8 @@

import {
IQueryFeaturesRequestOptions,
queryFeatures
queryFeatures,
IQueryFeaturesResponse
} from "@esri/arcgis-rest-feature-service";

import { getUser } from "@esri/arcgis-rest-users";
Expand Down Expand Up @@ -43,7 +44,7 @@ export function searchAnnotations(
const data: IResourceObject[] = [];

// use .reduce()?
response.features.forEach(function(comment) {
(response as IQueryFeaturesResponse).features.forEach(function(comment) {
const attributes = comment.attributes;
data.push({
id: attributes.author,
Expand Down
2 changes: 1 addition & 1 deletion packages/annotations/test/mocks/ago_search.ts
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
import { ISearchResult } from "@esri/arcgis-rest-items";

export const annoSearchResponse: ISearchResult = {
export const annoSearchResponse: any = {
query: "hubAnnotationLayer AND orgid:5bc",
total: 1,
start: 1,
Expand Down

0 comments on commit 301412f

Please sign in to comment.