[Trunk | Library]: piwik.service.ts: Change responseType from default (json) to blob (piwik returns image/gif)

git-svn-id: https://svn.driver.research-infrastructures.eu/driver/dnet40/modules/uoa-services-library/trunk/ng-openaire-library/src/app@56843 d315682c-612b-4755-9ff5-7f18f6832af3
This commit is contained in:
konstantina.galouni 2019-08-02 15:49:41 +00:00
parent 30bc39aa22
commit 0e59e7b6b4
1 changed files with 3 additions and 3 deletions

View File

@ -26,8 +26,8 @@ export class PiwikService {
((referrer != null && referrer.length > 0)?('&urlref='+StringUtils.URIEncode(referrer)):'');
//console.log("Piwik - View: " + url);
// return Observable.of(new Object()).mapTo(true); // for testing
return this.http.get( url);
// .do(request => console.info("Piwik request completed" ));
return this.http.get( url, {responseType: 'blob'});
// .do(request => console.info("Piwik request completed" ));
}
}
@ -39,7 +39,7 @@ export class PiwikService {
((referrer != null && referrer.length > 0)?('&urlref='+StringUtils.URIEncode(referrer)):'');
//console.log("Piwik - trackDownload: "+url);
return this.http.get( url);
return this.http.get( url, {responseType: 'blob'});
//.do(request => console.info("Piwik request completed" ));
}