From fe034c7bf682536f805caff808d89fd0d3c47c1b Mon Sep 17 00:00:00 2001 From: Kevin Ansfield Date: Thu, 24 Aug 2017 14:36:31 +0100 Subject: [PATCH] Fix caching headers --- ghost/admin/app/services/ajax.js | 1 + ghost/admin/app/services/unsplash.js | 2 +- 2 files changed, 2 insertions(+), 1 deletion(-) diff --git a/ghost/admin/app/services/ajax.js b/ghost/admin/app/services/ajax.js index 24bbed6fbc..788afae7c4 100644 --- a/ghost/admin/app/services/ajax.js +++ b/ghost/admin/app/services/ajax.js @@ -120,6 +120,7 @@ let ajaxService = AjaxService.extend({ let headers = {}; headers['X-Ghost-Version'] = config.APP.version; + headers['App-Pragma'] = 'no-cache'; if (session.get('isAuthenticated')) { session.authorize('authorizer:oauth2', (headerName, headerValue) => { diff --git a/ghost/admin/app/services/unsplash.js b/ghost/admin/app/services/unsplash.js index 38339832a8..a5148326f9 100644 --- a/ghost/admin/app/services/unsplash.js +++ b/ghost/admin/app/services/unsplash.js @@ -175,7 +175,7 @@ export default Service.extend({ headers.Authorization = `Client-ID ${this.get('applicationId')}`; headers['Accept-Version'] = API_VERSION; - headers['API-User-Agent'] = 'Ghost'; + headers['App-Pragma'] = 'no-cache'; return fetch(url, {headers}) .then((response) => this._checkStatus(response))