Skip to content

Commit

Permalink
Merge branch 'master' into no-stateless-class
Browse files Browse the repository at this point in the history
  • Loading branch information
niik committed Nov 15, 2016
2 parents 05fe9fc + cc0b4cf commit e340313
Show file tree
Hide file tree
Showing 8 changed files with 13 additions and 17 deletions.
1 change: 1 addition & 0 deletions app/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -23,6 +23,7 @@
"got": "^6.5.0",
"keytar": "^3.0.2",
"moment": "^2.14.1",
"node-uuid": "^1.4.7",
"octokat": "^0.5.0-beta.0",
"react": "^15.3.2",
"react-addons-css-transition-group": "^15.3.2",
Expand Down
3 changes: 3 additions & 0 deletions app/src/lib/dispatcher/background-fetcher.ts
Original file line number Diff line number Diff line change
Expand Up @@ -114,6 +114,9 @@ function skewInterval(): number {
return _skewInterval!
}

// We don't need cryptographically secure random numbers for
// the skew. Pseudo-random should be just fine.
// tslint:disable-next-line:insecure-random
const skew = Math.ceil(Math.random() * SkewUpperBound)
_skewInterval = skew
return skew
Expand Down
2 changes: 1 addition & 1 deletion app/src/lib/dispatcher/dispatcher.ts
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,6 @@ import { User, IUser } from '../../models/user'
import { Repository, IRepository } from '../../models/repository'
import { WorkingDirectoryFileChange, FileChange } from '../../models/status'
import { DiffSelection } from '../../models/diff'
import { guid } from '../guid'
import { RepositorySection, Popup, Foldout, IAppError } from '../app-state'
import { Action } from './actions'
import { AppStore } from './app-store'
Expand All @@ -14,6 +13,7 @@ import { Commit } from '../../models/commit'
import { IAPIUser } from '../../lib/api'
import { GitHubRepository } from '../../models/github-repository'
import { ICommitMessage } from './git-store'
import { v4 as guid } from 'node-uuid'

/**
* Extend Error so that we can create new Errors with a callstack different from
Expand Down
8 changes: 3 additions & 5 deletions app/src/lib/dispatcher/git-store.ts
Original file line number Diff line number Diff line change
Expand Up @@ -414,11 +414,9 @@ export class GitStore {
if (err) {
// An error most likely means the repository's never been published.
this._lastFetched = null
}

// If the file's empty then it _probably_ means the fetch failed and we
// shouldn't update the last fetched date.
if (stats.size > 0) {
} else if (stats.size > 0) {
// If the file's empty then it _probably_ means the fetch failed and we
// shouldn't update the last fetched date.
this._lastFetched = stats.mtime
}

Expand Down
8 changes: 0 additions & 8 deletions app/src/lib/guid.ts

This file was deleted.

2 changes: 1 addition & 1 deletion app/src/shared-process/auth.ts
Original file line number Diff line number Diff line change
@@ -1,10 +1,10 @@
import { shell } from 'electron'

import { guid } from '../lib/guid'
import { getDotComAPIEndpoint } from '../lib/api'
import { fatalError } from '../lib/fatal-error'
import * as appProxy from '../ui/lib/app-proxy'
import { IUser } from '../models/user'
import { v4 as guid } from 'node-uuid'

const ClientID = 'de0e3c7e9973e1c4dd77'
const ClientSecret = process.env.TEST_ENV ? '' : __OAUTH_SECRET__
Expand Down
5 changes: 3 additions & 2 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -45,7 +45,7 @@
"got": "^6.3.0",
"html-webpack-plugin": "^2.21.0",
"mocha": "^3.0.2",
"node-sass": "^3.7.0",
"node-sass": "^3.12.2",
"request": "^2.72.0",
"rimraf": "^2.5.2",
"sass-loader": "^3.2.0",
Expand All @@ -55,7 +55,7 @@
"ts-loader": "^0.8.2",
"ts-node": "^1.3.0",
"tslint": "^3.14.0",
"typescript": "^2.0.6",
"typescript": "^2.0.9",
"vrsource-tslint-rules": "^0.12.0",
"webpack": "^1.12.15",
"webpack-dev-middleware": "^1.6.1",
Expand All @@ -74,6 +74,7 @@
"@types/keytar": "^3.0.28",
"@types/mocha": "^2.2.29",
"@types/node": "^6.0.31",
"@types/node-uuid": "0.0.28",
"@types/react": "0.14.34",
"@types/react-addons-css-transition-group": "^0.14.17",
"@types/react-addons-test-utils": "^0.14.14",
Expand Down
1 change: 1 addition & 0 deletions tslint.json
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,7 @@
true,
"spaces"
],
"insecure-random": [ true ],
"interface-name": [ true, "always-prefix"],
"jsdoc-format": true,
"literal-spacing": [
Expand Down

0 comments on commit e340313

Please sign in to comment.