mirror of
https://github.com/scratchfoundation/scratch-www.git
synced 2025-02-19 19:07:47 -05:00
Do not try to manage fullscreen mode URI for unsaved projects
This fixes the issue where you could go from /projects/editor => /projects/0/fullscreen by entering fullscreen mode on a new unsaved project.
This commit is contained in:
parent
16ca2d7319
commit
c6961aae36
1 changed files with 3 additions and 0 deletions
|
@ -410,6 +410,9 @@ class Preview extends React.Component {
|
||||||
this.setState({isProjectLoaded: true});
|
this.setState({isProjectLoaded: true});
|
||||||
}
|
}
|
||||||
pushHistory (push) {
|
pushHistory (push) {
|
||||||
|
// Do not push history for projects without a real ID
|
||||||
|
if (this.state.projectId === '0') return;
|
||||||
|
|
||||||
// update URI to match mode
|
// update URI to match mode
|
||||||
const idPath = this.state.projectId ? `${this.state.projectId}/` : '';
|
const idPath = this.state.projectId ? `${this.state.projectId}/` : '';
|
||||||
let modePath = '';
|
let modePath = '';
|
||||||
|
|
Loading…
Reference in a new issue