Skip to content

Commit

Permalink
fix encrypt response parsing
Browse files Browse the repository at this point in the history
  • Loading branch information
ruddell committed Apr 8, 2020
1 parent 785fba9 commit 732c35d
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/main/webapp/app/registry/encryption/encryption.service.ts
Original file line number Diff line number Diff line change
Expand Up @@ -8,10 +8,10 @@ export class EncryptionService {
constructor(private http: HttpClient) {}

encrypt(textToEncrypt: string): Observable<string> {
return this.http.post<string>('config/encrypt', textToEncrypt).pipe(map((response: string) => '{cipher}' + response));
return this.http.post('config/encrypt', textToEncrypt, { responseType: 'text' }).pipe(map((response: string) => '{cipher}' + response));
}

decrypt(textToDecrypt: string): Observable<string> {
return this.http.post<string>('config/decrypt', textToDecrypt);
return this.http.post('config/decrypt', textToDecrypt, { responseType: 'text' });
}
}
1 change: 1 addition & 0 deletions webpack/webpack.dev.js
Original file line number Diff line number Diff line change
Expand Up @@ -21,6 +21,7 @@ module.exports = (options) => webpackMerge(commonConfig({ env: ENV }), {
context: [
'/api',
'/services',
'/config',
'/management',
'/swagger-resources',
'/v2/api-docs',
Expand Down

0 comments on commit 732c35d

Please sign in to comment.