Skip to content

Commit 3467463

Browse files
authored
Merge pull request #418 from sensebox/fix/connectAppRedirect
changes for old connect app
2 parents fba39a0 + 328a1e6 commit 3467463

File tree

1 file changed

+13
-3
lines changed

1 file changed

+13
-3
lines changed

src/components/Workspace/Compile.js

+13-3
Original file line numberDiff line numberDiff line change
@@ -135,9 +135,19 @@ class Compile extends Component {
135135
const filename = detectWhitespacesAndReturnReadableResult(
136136
this.state.name,
137137
);
138-
this.setState({
139-
link: `blocklyconnect-app://sketch/${filename}/${this.state.id}/${this.props.selectedBoard}`,
140-
});
138+
139+
140+
// TODO: When new connect app is released, the selected board can also be supplied with both boards
141+
if (this.props.selectedBoard === "esp32") {
142+
this.setState({
143+
link: `blocklyconnect-app://sketch/${filename}/${this.state.id}/${this.props.selectedBoard}`,
144+
});
145+
}
146+
else {
147+
this.setState({
148+
link: `blocklyconnect-app://sketch/${filename}/${this.state.id}`,
149+
});
150+
}
141151
this.setState({ appDialog: true });
142152
} else {
143153
if (this.state.name) {

0 commit comments

Comments
 (0)