fix: update googleapis to latest
This commit is contained in:
1130
api-server/package-lock.json
generated
1130
api-server/package-lock.json
generated
File diff suppressed because it is too large
Load Diff
@ -3,20 +3,19 @@
|
|||||||
"private": true,
|
"private": true,
|
||||||
"version": "0.0.1",
|
"version": "0.0.1",
|
||||||
"repository": "freecodecamp/freecodecamp",
|
"repository": "freecodecamp/freecodecamp",
|
||||||
"main": "development-entry.js",
|
|
||||||
"scripts": {
|
"scripts": {
|
||||||
"develop": "node development-start.js",
|
"develop": "DEBUG=fcc* node development-start.js",
|
||||||
"babel-dev-server": "babel-node --inspect=0.0.0.0 ./server/index.js",
|
"babel-dev-server": "babel-node --inspect=0.0.0.0 ./server/index.js",
|
||||||
"build": "babel server --out-dir lib --ignore 'node_modules /**/*','/**/*.test.js' --copy-files",
|
"build": "babel server --out-dir lib --ignore 'node_modules /**/*','/**/*.test.js' --copy-files",
|
||||||
"ensure-env": "node ../tools/scripts/build/ensure-env.js",
|
"ensure-env": "node ../tools/scripts/build/ensure-env.js",
|
||||||
"start": "DEBUG=fcc* babel-node server/index.js",
|
"start": "DEBUG=fcc* node production-start.js",
|
||||||
"test": "jest"
|
"test": "jest"
|
||||||
},
|
},
|
||||||
"license": "BSD-3-Clause",
|
"license": "BSD-3-Clause",
|
||||||
"dependencies": {
|
"dependencies": {
|
||||||
"@freecodecamp/loopback-component-passport": "^1.1.0",
|
"@freecodecamp/loopback-component-passport": "^1.1.0",
|
||||||
"accepts": "^1.3.7",
|
"accepts": "^1.3.7",
|
||||||
"auth0-js": "^9.10.4",
|
"auth0-js": "^9.11.3",
|
||||||
"body-parser": "^1.19.0",
|
"body-parser": "^1.19.0",
|
||||||
"chai": "~3.4.1",
|
"chai": "~3.4.1",
|
||||||
"compression": "^1.7.4",
|
"compression": "^1.7.4",
|
||||||
@ -33,9 +32,9 @@
|
|||||||
"express-session": "^1.16.2",
|
"express-session": "^1.16.2",
|
||||||
"express-state": "^1.2.0",
|
"express-state": "^1.2.0",
|
||||||
"express-validator": "^5.3.1",
|
"express-validator": "^5.3.1",
|
||||||
"googleapis": "^16.1.0",
|
"googleapis": "^42.0.0",
|
||||||
"helmet": "^3.18.0",
|
"helmet": "^3.20.0",
|
||||||
"helmet-csp": "^2.1.0",
|
"helmet-csp": "^2.8.0",
|
||||||
"jsonwebtoken": "^8.5.1",
|
"jsonwebtoken": "^8.5.1",
|
||||||
"lodash": "^4.17.15",
|
"lodash": "^4.17.15",
|
||||||
"loopback": "^3.26.0",
|
"loopback": "^3.26.0",
|
||||||
@ -51,16 +50,16 @@
|
|||||||
"normalize-url": "^1.3.1",
|
"normalize-url": "^1.3.1",
|
||||||
"normalizr": "^2.2.1",
|
"normalizr": "^2.2.1",
|
||||||
"passport": "^0.4.0",
|
"passport": "^0.4.0",
|
||||||
"passport-auth0": "^1.1.0",
|
"passport-auth0": "^1.2.0",
|
||||||
"passport-local": "^1.0.0",
|
"passport-local": "^1.0.0",
|
||||||
"passport-oauth": "^1.0.0",
|
"passport-oauth": "^1.0.0",
|
||||||
"query-string": "^6.8.0",
|
"query-string": "^6.8.2",
|
||||||
"redux": "^4.0.1",
|
"redux": "^4.0.4",
|
||||||
"redux-actions": "^2.6.5",
|
"redux-actions": "^2.6.5",
|
||||||
"redux-saga": "^0.16.0",
|
"redux-saga": "^0.16.0",
|
||||||
"reselect": "^3.0.1",
|
"reselect": "^3.0.1",
|
||||||
"rollbar": "^2.7.1",
|
"rollbar": "^2.11.0",
|
||||||
"rss-parser": "^3.7.1",
|
"rss-parser": "^3.7.2",
|
||||||
"rx": "^4.1.0",
|
"rx": "^4.1.0",
|
||||||
"shortid": "^2.2.14",
|
"shortid": "^2.2.14",
|
||||||
"stripe": "^6.1.0",
|
"stripe": "^6.1.0",
|
||||||
@ -68,13 +67,13 @@
|
|||||||
"validator": "^9.4.1"
|
"validator": "^9.4.1"
|
||||||
},
|
},
|
||||||
"devDependencies": {
|
"devDependencies": {
|
||||||
"@babel/cli": "^7.4.4",
|
"@babel/cli": "^7.5.5",
|
||||||
"@babel/core": "^7.4.5",
|
"@babel/core": "^7.5.5",
|
||||||
"@babel/node": "^7.5.5",
|
"@babel/node": "^7.5.5",
|
||||||
"@babel/plugin-proposal-class-properties": "^7.4.4",
|
"@babel/plugin-proposal-class-properties": "^7.5.5",
|
||||||
"@babel/plugin-proposal-object-rest-spread": "^7.4.4",
|
"@babel/plugin-proposal-object-rest-spread": "^7.5.5",
|
||||||
"@babel/preset-env": "^7.4.5",
|
"@babel/preset-env": "^7.5.5",
|
||||||
"@babel/register": "^7.4.4",
|
"@babel/register": "^7.5.5",
|
||||||
"adler32": "~0.1.7",
|
"adler32": "~0.1.7",
|
||||||
"babel-core": "^7.0.0-bridge.0",
|
"babel-core": "^7.0.0-bridge.0",
|
||||||
"babel-jest": "^24.8.0",
|
"babel-jest": "^24.8.0",
|
||||||
|
@ -2,7 +2,7 @@ import _ from 'lodash';
|
|||||||
import debug from 'debug';
|
import debug from 'debug';
|
||||||
import dedent from 'dedent';
|
import dedent from 'dedent';
|
||||||
import fs from 'fs';
|
import fs from 'fs';
|
||||||
import goog from 'googleapis';
|
import { google } from 'googleapis';
|
||||||
import { Observable } from 'rx';
|
import { Observable } from 'rx';
|
||||||
|
|
||||||
import { timeCache, observeMethod } from './rx';
|
import { timeCache, observeMethod } from './rx';
|
||||||
@ -13,7 +13,7 @@ const scope = 'https://www.googleapis.com/auth/analytics.readonly';
|
|||||||
const pathToCred = process.env.GOOGLE_APPLICATION_CREDENTIALS;
|
const pathToCred = process.env.GOOGLE_APPLICATION_CREDENTIALS;
|
||||||
|
|
||||||
const log = debug('fcc:server:utils:about');
|
const log = debug('fcc:server:utils:about');
|
||||||
const analytics = goog.analytics('v3');
|
const analytics = google.analytics('v3');
|
||||||
const makeRequest = observeMethod(analytics.data.realtime, 'get');
|
const makeRequest = observeMethod(analytics.data.realtime, 'get');
|
||||||
export const toBoundInt = _.flow(
|
export const toBoundInt = _.flow(
|
||||||
// first convert string to integer
|
// first convert string to integer
|
||||||
@ -60,7 +60,7 @@ export function createActiveUsers() {
|
|||||||
return zero;
|
return zero;
|
||||||
}
|
}
|
||||||
|
|
||||||
const client = new goog.auth.JWT(
|
const client = new google.auth.JWT(
|
||||||
credentials['client_email'],
|
credentials['client_email'],
|
||||||
null,
|
null,
|
||||||
credentials['private_key'],
|
credentials['private_key'],
|
||||||
|
Reference in New Issue
Block a user