From 6da7985a2e2700239eec572d76bb35d2625214c5 Mon Sep 17 00:00:00 2001 From: clomie Date: Sun, 3 Mar 2019 12:33:43 +0900 Subject: [PATCH] [google.script.client-side] Fix type assertion --- .../google.script.client-side-tests.ts | 14 +++++++------- 1 file changed, 7 insertions(+), 7 deletions(-) diff --git a/types/google.script.client-side/google.script.client-side-tests.ts b/types/google.script.client-side/google.script.client-side-tests.ts index 5e3c059c01..b0cb508777 100644 --- a/types/google.script.client-side/google.script.client-side-tests.ts +++ b/types/google.script.client-side/google.script.client-side-tests.ts @@ -1,7 +1,7 @@ google.script.url.getLocation(location => { - location.hash; // $ExpectedType string - location.parameter; // $ExpectedType { [key: string]: string } - location.parameters; // $ExpectedType { [key: string]: ReadonlyArray } + location.hash; // $ExpectType string + location.parameter; // $ExpectType { [key: string]: string; } + location.parameters; // $ExpectType { [key: string]: ReadonlyArray; } }); google.script.history.push(null); @@ -13,10 +13,10 @@ google.script.history.replace({ timestamp: Date.now() }, { foo: 'bar', fiz: 'baz google.script.history.replace({ timestamp: Date.now() }, { foo: ['bar', 'cat'], fiz: 'baz' }, 'anchor1'); google.script.history.setChangeHandler(e => { - e.state; // $ExpectedType google.script.history.State - e.location.hash; // $ExpectedType string - e.location.parameter; // $ExpectedType { [key: string]: string } - e.location.parameters; // $ExpectedType { [key: string]: ReadonlyArray } + e.state; // $ExpectType State + e.location.hash; // $ExpectType string + e.location.parameter; // $ExpectType { [key: string]: string; } + e.location.parameters; // $ExpectType { [key: string]: ReadonlyArray; } }); google.script.host.origin; // $ExpectType string