Skip to content

Commit

Permalink
Merge remote-tracking branch 'pm/develop' into merge-upstream
Browse files Browse the repository at this point in the history
  • Loading branch information
someCatInTheWorld committed Dec 8, 2024
2 parents 5d0f07a + ce7db9e commit d261f3d
Show file tree
Hide file tree
Showing 3 changed files with 24 additions and 23 deletions.
5 changes: 5 additions & 0 deletions src/components/tw-studioview/studioview.jsx
Original file line number Diff line number Diff line change
Expand Up @@ -60,6 +60,11 @@ class StudioViewComponent extends React.Component {
}
handleSelect (id) {
this.props.onSelect(id);
/**
* fuck this bullshity ass design paradigm, i cant find where the FUCK this event chain actually ends
* implicitly assume that what ever the fuck happens above will synchronously put the id into the url to be used later
*/
window.location.reload();
}
ref (el) {
this.el = el;
Expand Down
40 changes: 18 additions & 22 deletions src/lib/tw-project-meta-fetcher-hoc.jsx
Original file line number Diff line number Diff line change
Expand Up @@ -122,31 +122,27 @@ const TWProjectMetaFetcherHOC = function (WrappedComponent) {
new Date(rawData.date),
rawData.updating === true
);
}
if (rawData.remix > 0) {
// this is a remix, find the original project
fetchProjectMeta(rawData.remix)
.then(remixProject => {
// If project ID changed, ignore the results.
if (this.props.projectId !== projectId) {
return;
}
// If this project is hidden or not approved, ignore the results.
if (
typeof remixProject.name === 'string'
|| typeof remixProject.owner === 'string'
) {

if (String(rawData.remix) !== '0') {
// this is a remix, find the original project
fetchProjectMeta(rawData.remix)
.then(remixProject => {
// If project ID changed, ignore the results.
if (this.props.projectId !== projectId) {
return;
}

this.props.onSetRemixedProjectInfo(
true, // loaded
remixProject.name,
remixProject.owner
remixProject.title,
remixProject.author.username
);
}
})
.catch(err => {
// this isnt fatal, just log
log.warn('cannot fetch remixed project meta for this project;', err);
});
})
.catch(err => {
// this isnt fatal, just log
log.warn('cannot fetch remixed project meta for this project;', err);
});
}
}
setIndexable(true);
})
Expand Down
2 changes: 1 addition & 1 deletion src/playground/addon-settings.jsx
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@ import appTarget from './app-target';

const onExportSettings = settings => {
const blob = new Blob([JSON.stringify(settings)]);
downloadBlob('turbowarp-addon-settings.json', blob);
downloadBlob('penguinmod-addon-settings.json', blob);
};

ReactDOM.render((
Expand Down

0 comments on commit d261f3d

Please sign in to comment.