Skip to content

Commit 4c1f5a0

Browse files
Refactored the HTTP download code to automatically follow HTTP redirects
1 parent 3e10147 commit 4c1f5a0

File tree

12 files changed

+710
-452
lines changed

12 files changed

+710
-452
lines changed

.eslintrc

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -242,7 +242,7 @@
242242
"padded-blocks": [2, "never"], // enforce padding within blocks (off by default)
243243
"quote-props": [2, "as-needed"], // require quotes around object literal property names (off by default)
244244
"quotes": [2, "single"], // specify whether double or single quotes should be used
245-
"require-jsdoc": 2, // require JSDoc comment
245+
"require-jsdoc": 1, // require JSDoc comment
246246
"semi": [2, "always"], // require or disallow use of semicolons instead of ASI
247247
"semi-spacing": [2, { // enforce spacing before and after semicolons
248248
"before": false, // require a space before semicolons

CHANGELOG.md

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -3,6 +3,15 @@ All notable changes will be documented in this file.
33
JSON Schema $Ref Parser adheres to [Semantic Versioning](http://semver.org/).
44

55

6+
## [v2.1.0](https://github.com/BigstickCarpet/json-schema-ref-parser/tree/v2.1.0) (2015-12-31)
7+
8+
JSON Schema $Ref Parser now automatically follows HTTP redirects. This is especially great for servers that automatically "ugrade" your connection from HTTP to HTTPS via a 301 redirect. Now that won't break your code.
9+
10+
There are a few [new options](https://github.com/BigstickCarpet/json-schema-ref-parser/blob/master/docs/options.md) that allow you to set the number of redirects (default is 5) and a few other HTTP request properties.
11+
12+
[Full Changelog](https://github.com/BigstickCarpet/json-schema-ref-parser/compare/v2.0.0...v2.1.0)
13+
14+
615
## [v2.0.0](https://github.com/BigstickCarpet/json-schema-ref-parser/tree/v2.0.0) (2015-12-31)
716

817
Bumping the major version number because [this change](https://github.com/BigstickCarpet/json-schema-ref-parser/pull/5) technically breaks backward-compatibility — although I doubt it will actually affect many people. Basically, if you're using JSON Schema $Ref Parser to download files from a CORS-enabled server that requires authentication, then you'll need to set the `http.withCredentials` option to `true`.

0 commit comments

Comments
 (0)