Skip to content

Commit

Permalink
feat(*): upgrade deps. Correction for ts update
Browse files Browse the repository at this point in the history
  • Loading branch information
eyolas committed Nov 3, 2017
1 parent f66d930 commit 274e238
Show file tree
Hide file tree
Showing 8 changed files with 64 additions and 77 deletions.
2 changes: 1 addition & 1 deletion examples/express-passport/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@
"@gabliam/core": "^4.0.0",
"@gabliam/express": "^4.0.0",
"body-parser": "^1.16.1",
"celebrate": "^5.0.1",
"celebrate": "^6.0.0",
"cerialize": "^0.1.18",
"express-session": "^1.15.6",
"helmet": "^3.4.0",
Expand Down
4 changes: 2 additions & 2 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@
"precommit": "lint-staged",
"bootstrap": "yarn run build",
"changelog": "conventional-changelog -i CHANGELOG.md -p angular -s -r 0",
"lint": "tslint --type-check --project tsconfig.json \"./{packages,examples}/**/src/**/*.ts\" --exclude \"./{packages,examples}/**/node_modules/**/*.ts\" --exclude \"./{packages,examples}/**/src/**/*.d.ts\"",
"lint": "tslint --project tsconfig.json \"./{packages,examples}/**/src/**/*.ts\" --exclude \"./{packages,examples}/**/node_modules/**/*.ts\" --exclude \"./{packages,examples}/**/src/**/*.d.ts\"",
"build": "lerna run build",
"test": "jest --runInBand",
"test:ci": "jest --runInBand --coverage && yarn run coverage",
Expand All @@ -25,7 +25,7 @@
"@types/reflect-metadata": "^0.0.5",
"@types/sinon": "^2.3.5",
"@types/supertest": "^2.0.3",
"codecov": "^2.3.0",
"codecov": "^3.0.0",
"commitizen": "^2.9.6",
"conventional-changelog-cli": "^1.3.4",
"cz-conventional-changelog": "^2.0.0",
Expand Down
2 changes: 1 addition & 1 deletion packages/amqp/src/amqp-connection.ts
Original file line number Diff line number Diff line change
Expand Up @@ -164,7 +164,7 @@ export class AmqpConnection {
if (timeout) {
promise = promise.timeout(timeout).catch(PromiseB.TimeoutError, e => {
onTimeout = true;
throw new AmqpTimeout(e.message);
throw new AmqpTimeout((<any>e).message);
});
}

Expand Down
19 changes: 13 additions & 6 deletions packages/express/src/decorators/params.ts
Original file line number Diff line number Diff line change
Expand Up @@ -18,12 +18,19 @@ function paramDecoratorFactory(
};
}

export function Params(type: PARAMETER_TYPE, parameterName: string) {
return function(target: Object, methodName: string, index: number) {
export function Params(
type: PARAMETER_TYPE,
parameterName: string
): ParameterDecorator {
return function(
target: Object,
propertyKey: string | symbol,
parameterIndex: number
) {
let metadataList: ControllerParameterMetadata = {};
let parameterMetadataList: ParameterMetadata[] = [];
const parameterMetadata: ParameterMetadata = {
index: index,
index: parameterIndex,
parameterName: parameterName,
type: type
};
Expand All @@ -39,12 +46,12 @@ export function Params(type: PARAMETER_TYPE, parameterName: string) {
METADATA_KEY.controllerParameter,
target.constructor
);
if (metadataList.hasOwnProperty(methodName)) {
parameterMetadataList = metadataList[methodName];
if (metadataList.hasOwnProperty(propertyKey)) {
parameterMetadataList = metadataList[propertyKey];
}
parameterMetadataList.unshift(parameterMetadata);
}
metadataList[methodName] = parameterMetadataList;
metadataList[propertyKey] = parameterMetadataList;
Reflect.defineMetadata(
METADATA_KEY.controllerParameter,
metadataList,
Expand Down
2 changes: 1 addition & 1 deletion packages/express/src/express-plugin.ts
Original file line number Diff line number Diff line change
Expand Up @@ -128,7 +128,7 @@ export class ExpressPlugin implements GabliamPlugin {
const port = restConfig.port;
app.set('port', port);

const server = http.createServer(app);
const server = http.createServer(<any>app);
server.listen(port, restConfig.hostname);
server.on('error', onError);
server.on('listening', onListening);
Expand Down
12 changes: 7 additions & 5 deletions packages/graphql/src/graphql-plugin.ts
Original file line number Diff line number Diff line change
Expand Up @@ -28,6 +28,7 @@ import * as bodyParser from 'body-parser';
import * as _ from 'lodash';
import * as fs from 'fs';
import * as d from 'debug';
import { GraphQLOptions } from 'apollo-server-core';

const debug = d(DEBUG_PATH);

Expand Down Expand Up @@ -160,19 +161,20 @@ export class GraphqlPlugin implements GabliamPlugin {

app.use(
graphqlPluginConfig.endpointUrl,
graphqlExpress(((req: any) => {
graphqlExpress(<ExpressGraphQLOptionsFunction>((req: any) => {
let options = {};

/* istanbul ignore if */
if ((<any>req).graphqlOptions) {
options = (<any>req).graphqlOptions;
}

return {
// makeExecutableSchema and ExpressGraphQLOptionsFunction use different version of GraphQLSchema typings
// (GraphQLOptions use apollo-server-core and makeExecutableSchema use @types/graphql)
return <GraphQLOptions>(<any>{
schema: executableSchema,
...options
};
}) as ExpressGraphQLOptionsFunction)
});
}))
);

if (graphqlPluginConfig.graphiqlEnabled) {
Expand Down
1 change: 1 addition & 0 deletions tsconfig.json
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,7 @@
"noUnusedLocals": true,
"noFallthroughCasesInSwitch": true,
"skipLibCheck": true,
"skipDefaultLibCheck": true,
"sourceMap": true
}
}
99 changes: 38 additions & 61 deletions yarn.lock
Original file line number Diff line number Diff line change
Expand Up @@ -3,8 +3,8 @@


"@types/bluebird@^3.5.8":
version "3.5.17"
resolved "https://registry.yarnpkg.com/@types/bluebird/-/bluebird-3.5.17.tgz#f9eee76920e7aded0f665ee7658c058407bd12ff"
version "3.5.18"
resolved "https://registry.yarnpkg.com/@types/bluebird/-/bluebird-3.5.18.tgz#6a60435d4663e290f3709898a4f75014f279c4d6"

"@types/body-parser@*", "@types/body-parser@^1.16.3", "@types/body-parser@^1.16.4":
version "1.16.7"
Expand All @@ -30,8 +30,8 @@
resolved "https://registry.yarnpkg.com/@types/debug/-/debug-0.0.30.tgz#dc1e40f7af3b9c815013a7860e6252f6352a84df"

"@types/express-serve-static-core@*":
version "4.0.55"
resolved "https://registry.yarnpkg.com/@types/express-serve-static-core/-/express-serve-static-core-4.0.55.tgz#f53868838a955f98b380819ec9134f5df7d9482f"
version "4.0.56"
resolved "https://registry.yarnpkg.com/@types/express-serve-static-core/-/express-serve-static-core-4.0.56.tgz#4ed556dcff9012cce6b016e214fdc5ef6e99db7d"
dependencies:
"@types/node" "*"

Expand Down Expand Up @@ -901,13 +901,13 @@ caseless@~0.12.0:
version "0.12.0"
resolved "https://registry.yarnpkg.com/caseless/-/caseless-0.12.0.tgz#1b681c21ff84033c826543090689420d187151dc"

celebrate@^5.0.1:
version "5.0.1"
resolved "https://registry.yarnpkg.com/celebrate/-/celebrate-5.0.1.tgz#63e2b706f74ca4edfde6b41024e6e05186bbf972"
celebrate@^6.0.0:
version "6.0.0"
resolved "https://registry.yarnpkg.com/celebrate/-/celebrate-6.0.0.tgz#60258d879e9d819988a5923b4c0e9ab03a444282"
dependencies:
escape-html "1.0.3"
fastseries "1.7.2"
joi "11.x.x"
joi "12.x.x"

center-align@^0.1.1:
version "0.1.3"
Expand Down Expand Up @@ -1067,12 +1067,12 @@ code-point-at@^1.0.0:
version "1.1.0"
resolved "https://registry.yarnpkg.com/code-point-at/-/code-point-at-1.1.0.tgz#0d070b4d043a5bea33a2f1a40e2edb3d9a4ccf77"

codecov@^2.3.0:
version "2.3.1"
resolved "https://registry.yarnpkg.com/codecov/-/codecov-2.3.1.tgz#7dda945cd58a1f6081025b5b03ee01a2ef20f86e"
codecov@^3.0.0:
version "3.0.0"
resolved "https://registry.yarnpkg.com/codecov/-/codecov-3.0.0.tgz#c273b8c4f12945723e8dc9d25803d89343e5f28e"
dependencies:
argv "0.0.2"
request "2.77.0"
request "2.81.0"
urlgrey "0.4.4"

color-convert@^1.9.0:
Expand Down Expand Up @@ -1637,6 +1637,10 @@ detect-indent@^5.0.0:
version "5.0.0"
resolved "https://registry.yarnpkg.com/detect-indent/-/detect-indent-5.0.0.tgz#3871cc0a6a002e8c3e5b3cf7f336264675f06b9d"

detect-libc@^1.0.2:
version "1.0.2"
resolved "https://registry.yarnpkg.com/detect-libc/-/detect-libc-1.0.2.tgz#71ad5d204bf17a6a6ca8f450c61454066ef461e1"

diff@^3.1.0, diff@^3.2.0:
version "3.4.0"
resolved "https://registry.yarnpkg.com/diff/-/diff-3.4.0.tgz#b1d85507daf3964828de54b37d0d73ba67dda56c"
Expand Down Expand Up @@ -2952,8 +2956,8 @@ inversify-logger-middleware@^3.0.0:
chalk "^1.1.3"

inversify@^4.3.0:
version "4.3.0"
resolved "https://registry.yarnpkg.com/inversify/-/inversify-4.3.0.tgz#d2ecd2ae18340e7f1ab5148a3e44b87080391366"
version "4.5.0"
resolved "https://registry.yarnpkg.com/inversify/-/inversify-4.5.0.tgz#1a575ddf1db216ed3292d9b0f70f497de275874e"

invert-kv@^1.0.0:
version "1.0.0"
Expand Down Expand Up @@ -3506,9 +3510,9 @@ jest@^21.2.1:
dependencies:
jest-cli "^21.2.1"

joi@11.x.x:
version "11.4.0"
resolved "https://registry.yarnpkg.com/joi/-/joi-11.4.0.tgz#f674897537b625e9ac3d0b7e1604c828ad913ccb"
joi@12.x.x:
version "12.0.0"
resolved "https://registry.yarnpkg.com/joi/-/joi-12.0.0.tgz#46f55e68f4d9628f01bbb695902c8b307ad8d33a"
dependencies:
hoek "4.x.x"
isemail "3.x.x"
Expand Down Expand Up @@ -3634,8 +3638,8 @@ jsprim@^1.2.2:
verror "1.10.0"

just-extend@^1.1.26:
version "1.1.26"
resolved "https://registry.yarnpkg.com/just-extend/-/just-extend-1.1.26.tgz#dba4ad2786d319f1d10afab106e004b5a0851ac2"
version "1.1.27"
resolved "https://registry.yarnpkg.com/just-extend/-/just-extend-1.1.27.tgz#ec6e79410ff914e472652abfa0e603c03d60e905"

kareem@1.5.0:
version "1.5.0"
Expand Down Expand Up @@ -3690,8 +3694,8 @@ lcid@^1.0.0:
invert-kv "^1.0.0"

lerna@^2.2.0:
version "2.4.0"
resolved "https://registry.yarnpkg.com/lerna/-/lerna-2.4.0.tgz#7b76446b154bafb9cba8996f3dc233f1cb6ca7c3"
version "2.5.1"
resolved "https://registry.yarnpkg.com/lerna/-/lerna-2.5.1.tgz#d07099bd3051ee799f98c753328bd69e96c6fab8"
dependencies:
async "^1.5.0"
chalk "^2.1.0"
Expand All @@ -3717,6 +3721,7 @@ lerna@^2.2.0:
minimatch "^3.0.4"
npmlog "^4.1.2"
p-finally "^1.0.0"
package-json "^4.0.1"
path-exists "^3.0.0"
read-cmd-shim "^1.0.1"
read-pkg "^2.0.0"
Expand Down Expand Up @@ -4046,8 +4051,8 @@ log-update@^1.0.2:
cli-cursor "^1.0.2"

log4js@^2.3.3:
version "2.3.10"
resolved "https://registry.yarnpkg.com/log4js/-/log4js-2.3.10.tgz#2f4f5423613c2ea535e6e3b081cebae64d320887"
version "2.3.11"
resolved "https://registry.yarnpkg.com/log4js/-/log4js-2.3.11.tgz#b61b7ef3d6e2c9ce5e1d0f5081a379d48e2d7600"
dependencies:
date-format "^1.1.0"
debug "^2.6.8"
Expand Down Expand Up @@ -4292,8 +4297,8 @@ mongodb@2.2.33:
readable-stream "2.2.7"

mongoose@^4.12.3, mongoose@^4.8.5:
version "4.12.5"
resolved "https://registry.yarnpkg.com/mongoose/-/mongoose-4.12.5.tgz#c5fecc40a48402120e9a2cf5bd27a674da9ce331"
version "4.12.6"
resolved "https://registry.yarnpkg.com/mongoose/-/mongoose-4.12.6.tgz#04bfa0b550d2cd951e2d71a81be8644ec1cf2fe7"
dependencies:
async "2.1.4"
bson "~1.0.4"
Expand Down Expand Up @@ -4417,9 +4422,10 @@ node-notifier@^5.0.2:
which "^1.2.12"

node-pre-gyp@^0.6.36, node-pre-gyp@~0.6.38:
version "0.6.38"
resolved "https://registry.yarnpkg.com/node-pre-gyp/-/node-pre-gyp-0.6.38.tgz#e92a20f83416415bb4086f6d1fb78b3da73d113d"
version "0.6.39"
resolved "https://registry.yarnpkg.com/node-pre-gyp/-/node-pre-gyp-0.6.39.tgz#c00e96860b23c0e1420ac7befc5044e1d78d8649"
dependencies:
detect-libc "^1.0.2"
hawk "3.1.3"
mkdirp "^0.5.1"
nopt "^4.0.1"
Expand Down Expand Up @@ -4762,7 +4768,7 @@ package-json@^2.0.0:
registry-url "^3.0.3"
semver "^5.1.0"

package-json@^4.0.0:
package-json@^4.0.0, package-json@^4.0.1:
version "4.0.1"
resolved "https://registry.yarnpkg.com/package-json/-/package-json-4.0.1.tgz#8869a0401253661c4c4ca3da6c2121ed555f5eed"
dependencies:
Expand Down Expand Up @@ -5083,10 +5089,6 @@ qs@~6.2.0:
version "6.2.3"
resolved "https://registry.yarnpkg.com/qs/-/qs-6.2.3.tgz#1cfcb25c10a9b2b483053ff39f5dfc9233908cfe"

qs@~6.3.0:
version "6.3.2"
resolved "https://registry.yarnpkg.com/qs/-/qs-6.3.2.tgz#e75bd5f6e268122a2a0e0bda630b2550c166502c"

qs@~6.4.0:
version "6.4.0"
resolved "https://registry.yarnpkg.com/qs/-/qs-6.4.0.tgz#13e26d28ad6b0ffaa91312cd3bf708ed351e7233"
Expand Down Expand Up @@ -5363,31 +5365,6 @@ request@2.75.x:
tough-cookie "~2.3.0"
tunnel-agent "~0.4.1"

request@2.77.0:
version "2.77.0"
resolved "https://registry.yarnpkg.com/request/-/request-2.77.0.tgz#2b00d82030ededcc97089ffa5d8810a9c2aa314b"
dependencies:
aws-sign2 "~0.6.0"
aws4 "^1.2.1"
caseless "~0.11.0"
combined-stream "~1.0.5"
extend "~3.0.0"
forever-agent "~0.6.1"
form-data "~2.1.1"
har-validator "~2.0.6"
hawk "~3.1.3"
http-signature "~1.1.0"
is-typedarray "~1.0.0"
isstream "~0.1.2"
json-stringify-safe "~5.0.1"
mime-types "~2.1.7"
node-uuid "~1.4.7"
oauth-sign "~0.8.1"
qs "~6.3.0"
stringstream "~0.0.4"
tough-cookie "~2.3.0"
tunnel-agent "~0.4.1"

request@2.81.0:
version "2.81.0"
resolved "https://registry.yarnpkg.com/request/-/request-2.81.0.tgz#c6928946a0e06c5f8d6f8a9333469ffda46298a0"
Expand Down Expand Up @@ -6399,8 +6376,8 @@ typeorm@^0.1.1:
yargs "^9.0.1"

typescript@^2.5.0, typescript@^2.5.3:
version "2.5.3"
resolved "https://registry.yarnpkg.com/typescript/-/typescript-2.5.3.tgz#df3dcdc38f3beb800d4bc322646b04a3f6ca7f0d"
version "2.6.1"
resolved "https://registry.yarnpkg.com/typescript/-/typescript-2.6.1.tgz#ef39cdea27abac0b500242d6726ab90e0c846631"

uglify-js@^2.6:
version "2.8.29"
Expand Down Expand Up @@ -6646,8 +6623,8 @@ wordwrap@~0.0.2:
resolved "https://registry.yarnpkg.com/wordwrap/-/wordwrap-0.0.3.tgz#a3d5da6cd5c0bc0008d37234bbaf1bed63059107"

worker-farm@^1.3.1:
version "1.5.0"
resolved "https://registry.yarnpkg.com/worker-farm/-/worker-farm-1.5.0.tgz#adfdf0cd40581465ed0a1f648f9735722afd5c8d"
version "1.5.1"
resolved "https://registry.yarnpkg.com/worker-farm/-/worker-farm-1.5.1.tgz#8e9f4a7da4f3c595aa600903051b969390423fa1"
dependencies:
errno "^0.1.4"
xtend "^4.0.1"
Expand Down

0 comments on commit 274e238

Please sign in to comment.