Skip to content

Commit

Permalink
* Removed TypeScript linter warning message (checks for no unused var…
Browse files Browse the repository at this point in the history
…iables)

* NPM updates related to the Node TypeScript typings
* Dependency "ta-json" updates, and NPM integration GitHub semver reference
* NPM r2-utils-js dep update
* Fixed TypeScript regression bug (3.0.3 -> 3.1.1) related to LCP typings

version bump 1.0.0-alpha.5
  • Loading branch information
danielweck committed Oct 2, 2018
1 parent e5daed7 commit 50747b4
Show file tree
Hide file tree
Showing 6 changed files with 69 additions and 54 deletions.
21 changes: 20 additions & 1 deletion CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,7 +1,26 @@
# Next

Git diff:
* https://github.com/readium/r2-lcp-js/compare/v1.0.0-alpha.4...develop
* https://github.com/readium/r2-lcp-js/compare/v1.0.0-alpha.5...develop

# 1.0.0-alpha.5

Changes:
* Removed TypeScript linter warning message (checks for no unused variables)
* NPM updates related to the Node TypeScript typings
* Dependency "ta-json" updates, and NPM integration GitHub semver reference
* NPM r2-utils-js dep update
* Fixed TypeScript regression bug (3.0.3 -> 3.1.1) related to LCP typings

Git revision info:
* https://unpkg.com/r2-lcp-js@1.0.0-alpha.5/dist/gitrev.json
* https://github.com/edrlab/r2-lcp-js-dist/blob/v1.0.0-alpha.5/dist/gitrev.json

Git commit history:
* https://github.com/readium/r2-lcp-js/commits/v1.0.0-alpha.5

Git diff:
* https://github.com/readium/r2-lcp-js/compare/v1.0.0-alpha.4...v1.0.0-alpha.5

# 1.0.0-alpha.4

Expand Down
81 changes: 37 additions & 44 deletions package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

10 changes: 5 additions & 5 deletions package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "r2-lcp-js",
"version": "1.0.0-alpha.4",
"version": "1.0.0-alpha.5",
"description": "Readium 2 LCP bits for NodeJS (TypeScript)",
"keywords": [
"readium",
Expand Down Expand Up @@ -49,16 +49,16 @@
"bindings": "^1.3.0",
"debug": "^4.0.1",
"moment": "^2.22.2",
"r2-utils-js": "^1.0.0-alpha.4",
"r2-utils-js": "^1.0.0-alpha.5",
"request": "^2.88.0",
"request-promise-native": "^1.0.5",
"ta-json": "github:danielweck/ta-json#dist",
"ta-json": "git://github.com/danielweck/ta-json.git#semver:^2.5.0",
"tslib": "^1.9.3",
"urijs": "^1.19.1"
},
"devDependencies": {
"@types/debug": "^0.0.30",
"@types/node": "8.*.*",
"@types/node": "^8.10.32",
"@types/request": "^2.47.1",
"@types/request-promise-native": "^1.0.15",
"@types/urijs": "^1.15.38",
Expand All @@ -73,7 +73,7 @@
"rimraf": "^2.6.2",
"tslint": "^5.11.0",
"tslint-language-service": "^0.9.9",
"typescript": "^3.0.3"
"typescript": "^3.1.1"
},
"files": [
"LICENSE",
Expand Down
8 changes: 6 additions & 2 deletions src/transform/transformer-lcp.ts
Original file line number Diff line number Diff line change
Expand Up @@ -268,7 +268,9 @@ export async function transformStream(

// https://github.com/nodejs/node/blob/master/lib/crypto.js#L259
const decryptStream = crypto.createDecipheriv("aes-256-cbc",
lcp.ContentKey, // new Buffer(contentKey as string, "binary"),
// Note: assumes lcp.ContentKey has been set (can be undefined)
// (this is only for testing the pure JS implementation anyway)
lcp.ContentKey as Buffer, // new Buffer(contentKey as string, "binary"),
ivBuffer);
decryptStream.setAutoPadding(false);
rawDecryptStream.pipe(decryptStream);
Expand Down Expand Up @@ -499,7 +501,9 @@ export async function getDecryptedSizeStream(
// === shared-culture.mp4

const decryptStream = crypto.createDecipheriv("aes-256-cbc",
lcp.ContentKey, // new Buffer(contentKey as string, "binary"),
// Note: assumes lcp.ContentKey has been set (can be undefined)
// (this is only for testing the pure JS implementation anyway)
lcp.ContentKey as Buffer, // new Buffer(contentKey as string, "binary"),
ivBuffer);
decryptStream.setAutoPadding(false);

Expand Down
2 changes: 1 addition & 1 deletion tsconfigs/tsconfig-common.json
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@
"alwaysShowRuleFailuresAsWarnings": false,
"ignoreDefinitionFiles": true,
"configFile": "./tslint.json",
"disableNoUnusedVariableRule": true
"disableNoUnusedVariableRule": false
}
],
"rootDir": "../",
Expand Down
1 change: 0 additions & 1 deletion tslint.json
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,6 @@
"no-floating-promises": true,
"promise-function-async": true,
"await-promise": true,
"no-unused-variable": true,
"no-unused-expression": true,
"variable-name": [
true,
Expand Down

0 comments on commit 50747b4

Please sign in to comment.