Skip to content

Commit ab4acfa

Browse files
committed
fix loading for stage
1 parent 74380d7 commit ab4acfa

File tree

1 file changed

+4
-1
lines changed

1 file changed

+4
-1
lines changed

src/lib/project-fetcher-hoc.jsx

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -105,6 +105,10 @@ function protobufToJson(buffer) {
105105
rotationStyle: target.rotationStyle
106106
};
107107

108+
if (newTarget.isStage) {
109+
delete newTarget.visible, delete newTarget.size, delete newTarget.direction, delete newTarget.draggable, delete newTarget.rotationStyle;
110+
}
111+
108112
for (const variable in target.variables) {
109113
newTarget.variables[variable] = [target.variables[variable].name, target.variables[variable].value];
110114
}
@@ -286,7 +290,6 @@ const ProjectFetcherHOC = function (WrappedComponent) {
286290
assetPromise = storage.load(storage.AssetType.Project, projectId, storage.DataFormat.JSON);
287291
} else {
288292
projectUrl = `https://projects.penguinmod.com/api/v1/projects/getprojectwrapper?safe=true&projectId=${projectId}`
289-
// TODO: convert the protobuf to a pmp. Get the pbf file from the server to do this.
290293
assetPromise = progressMonitor.fetchWithProgress(projectUrl)
291294
.then(async r => {
292295
this.props.vm.runtime.renderer.setPrivateSkinAccess(false);

0 commit comments

Comments
 (0)