From 5cc60281b531de7b6edc857f213a9d57bf69c517 Mon Sep 17 00:00:00 2001 From: Keyan Zhang Date: Tue, 31 Oct 2017 23:47:15 -0700 Subject: [PATCH] prettier --- flow-typed/qs.js | 2 +- src/components/ErrorDecoder/ErrorDecoder.js | 6 ++++-- 2 files changed, 5 insertions(+), 3 deletions(-) diff --git a/flow-typed/qs.js b/flow-typed/qs.js index bd7c49936..eb06ded23 100644 --- a/flow-typed/qs.js +++ b/flow-typed/qs.js @@ -1,5 +1,5 @@ declare module 'qs' { declare module.exports: { - parse: (str: string, opts: Object) => Object; + parse: (str: string, opts: Object) => Object, }; } diff --git a/src/components/ErrorDecoder/ErrorDecoder.js b/src/components/ErrorDecoder/ErrorDecoder.js index c41a774e5..a53cfbe93 100644 --- a/src/components/ErrorDecoder/ErrorDecoder.js +++ b/src/components/ErrorDecoder/ErrorDecoder.js @@ -41,7 +41,9 @@ function urlify(str: string): Node { // `?invariant=123&args[]=foo&args[]=bar` // or `// ?invariant=123&args[0]=foo&args[1]=bar` -function parseQueryString(search: string): ?{code: string, args: Array} { +function parseQueryString( + search: string, +): ?{|code: string, args: Array|} { const qsResult = qs.parse(search, {ignoreQueryPrefix: true}); if (!qsResult.invariant) { return null; @@ -52,7 +54,7 @@ function parseQueryString(search: string): ?{code: string, args: Array} }; } -function ErrorResult(props: {code: ?string, msg: string}) { +function ErrorResult(props: {|code: ?string, msg: string|}) { const code = props.code; const errorMsg = props.msg;