Skip to content

Commit

Permalink
Removed cache buster from client extensions script (#20668)
Browse files Browse the repository at this point in the history
ref
https://linear.app/tryghost/issue/PA-71/remove-cache-bust-from-projs-in-admin
ref
15ed2eb

- This cache buster was added in March to mitigate a client side error in pro.js,
to effectively force browsers to redownload the fixed version of the file.
- It's not needed anymore, as the error has been fixed for a few months
now, so we can safely remove it.
  • Loading branch information
cmraible authored Jul 25, 2024
1 parent 23458c6 commit 71d830e
Show file tree
Hide file tree
Showing 2 changed files with 1 addition and 5 deletions.
4 changes: 0 additions & 4 deletions ghost/admin/app/controllers/application.js
Original file line number Diff line number Diff line change
Expand Up @@ -27,10 +27,6 @@ export default class ApplicationController extends Controller {
return this.config.clientExtensions?.script;
}

get cacheBuster() {
return Date.now();
}

get showNavMenu() {
let {router, session, ui} = this;

Expand Down
2 changes: 1 addition & 1 deletion ghost/admin/app/templates/application.hbs
Original file line number Diff line number Diff line change
Expand Up @@ -40,7 +40,7 @@
{{#if this.showScriptExtension}}
{{{this.showScriptExtension.container}}}
{{!-- template-lint-disable no-forbidden-elements --}}
<script src="{{this.showScriptExtension.src}}?v={{this.cacheBuster}}"></script>
<script src="{{this.showScriptExtension.src}}"></script>
{{/if}}

{{#if this.settings.accentColor}}
Expand Down

0 comments on commit 71d830e

Please sign in to comment.