diff --git a/lib/generator/angular.client/templates/services.ts.ejs b/lib/generator/angular.client/templates/services.ts.ejs index fd56db5..16523f5 100644 --- a/lib/generator/angular.client/templates/services.ts.ejs +++ b/lib/generator/angular.client/templates/services.ts.ejs @@ -38,7 +38,7 @@ export class <%- ctrl.name%>Service { const headers: Headers = new Headers(); headers.append('Content-Type', 'application/json'); headers.append('Accept', 'application/json'); - headers.append('Accept-Encoding', 'gzip, deflate, compress'); + // headers.append('Accept-Encoding', 'gzip, deflate, compress'); if(Configuration.customHeaders != null || Configuration.customHeaders !== undefined) { @@ -136,7 +136,7 @@ if(method.hasParameterType('path')) { _headers.append('x-access-token', Configuration.token); %><% }%> - return this.__http.<%- method.verb%>(__url<%if(needBody) {%>, _body<%}%>, _headers) + return this.__http.<%- method.verb%>(__url<%if(needBody) {%>, _body<%}%>, { headers: _headers } ) .map((response: Response) => <<%- resultTypeHttp %>> ( <% if(resultTypeIsPrimitive){ %>response.json()<% diff --git a/package.json b/package.json index 7b1ae9b..61f50cd 100644 --- a/package.json +++ b/package.json @@ -1,7 +1,7 @@ { "name": "nicassa-generator", "description": "CLI based code generator for Sequelize, Node, Typescript, Angular 2, Android, Swagger, ORM Lite", - "version": "0.0.34", + "version": "0.0.35", "author": "Harald Fielker ", "repository": { "type": "git",