MCPcopy Create free account
hub / github.com/compiler-explorer/compiler-explorer / ensureUrlIsNotOutdated

Method ensureUrlIsNotOutdated

static/sharing.ts:114–122  ·  view source on GitHub ↗
(config: any)

Source from the content-addressed store, hash-verified

112 }
113
114 protected ensureUrlIsNotOutdated(config: any): void {
115 const stringifiedConfig = JSON.stringify(config);
116 if (stringifiedConfig !== this.lastState) {
117 if (this.lastState != null && window.location.pathname !== window.httpRoot) {
118 window.history.replaceState(null, '', window.httpRoot);
119 }
120 this.lastState = stringifiedConfig;
121 }
122 }
123
124 public static filterComponentState(config: any): any {
125 function filterComponentStateImpl(component: any) {

Callers 1

onStateChangedMethod · 0.95

Calls

no outgoing calls

Tested by

no test coverage detected