Skip to content

Commit

Permalink
fix ts
Browse files Browse the repository at this point in the history
  • Loading branch information
schickling committed Mar 16, 2017
1 parent e77c572 commit b575bb8
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 2 deletions.
5 changes: 4 additions & 1 deletion custom.d.ts
Expand Up @@ -7,14 +7,17 @@ declare module 'graphiql'
declare module 'react-copy-to-clipboard'
declare module 'cuid'

declare var fetch: any
declare var Smooch: any
declare var __LAST_UPDATE__: string
declare var __LAMBDA_AUTH__: string
declare var __LAMBDA_DOWNLOAD_EXAMPLE__: string
declare var __GITHUB_OAUTH_CLIENT_ID__: string
declare var __GA_TRACKING_CODE__: string

interface Window {
Smooch: any
}

declare module 'react-relay' {

// fragments are a hash of functions
Expand Down
2 changes: 1 addition & 1 deletion src/components/SharePanel/SharePanel.tsx
Expand Up @@ -112,6 +112,6 @@ export default class SharePanel extends React.Component<Props, {}> {
private isDisplayed = () => {
const lastTimestamp = getStoredState().initialLoadTimestamp
const currentTimestamp = Date.now()
return (currentTimestamp - lastTimestamp) >= millUntilDisplay
return lastTimestamp && (currentTimestamp - lastTimestamp) >= millUntilDisplay
}
}

0 comments on commit b575bb8

Please sign in to comment.