Don't show the warning message when compiler is disabled (by URL parameter)

This commit is contained in:
Thomas Weber committed 2020-12-22 15:23:54 -06:00
1 parent 2576eedf37
commit cf160bc275
1 file changed
+7 -4
+7 -4
View File
@@ -16,10 +16,13 @@ const TWEditorWarningHOC = function (WrappedComponent) {
}
enableWarpTimerIfInEditor () {
if (!this.props.isPlayerOnly) {
this.props.onShowWarning();
this.props.vm.setCompilerOptions({
warpTimer: true
});
// If compiler is already disabled, don't show the warning or change warp timer.
if (this.props.compilerOptions.enabled) {
this.props.onShowWarning();
this.props.vm.setCompilerOptions({
warpTimer: true
});
}
this.disabled = true;
}
}