@@ -150,11 +150,6 @@ type CallPythonFunctionExtraState = {
150150 * The mechanism class name. Specified only if the function kind is INSTANCE_MECHANISM.
151151 */
152152 mechanismClassName ?: string ,
153-
154- // The following fields allow Alan and Liz to load older projects.
155- // TODO(lizlooney): Remove these fields.
156- otherBlockId ?: string ,
157- mechanismBlockId ?: string ,
158153}
159154
160155const CALL_PYTHON_FUNCTION = {
@@ -303,7 +298,6 @@ const CALL_PYTHON_FUNCTION = {
303298 this : CallPythonFunctionBlock ,
304299 extraState : CallPythonFunctionExtraState
305300 ) : void {
306- fixOldExtraState ( extraState ) ;
307301 this . mrcFunctionKind = extraState . functionKind as FunctionKind ;
308302 this . mrcReturnType = extraState . returnType ;
309303 this . mrcArgs = [ ] ;
@@ -1276,26 +1270,3 @@ function createFireEventBlock(event: storageModuleContent.Event): toolboxItems.B
12761270 processArgs ( args , extraState , inputs ) ;
12771271 return createBlock ( extraState , fields , inputs ) ;
12781272}
1279-
1280- // The following function allows Alan and Liz to load older projects.
1281- // TODO(lizlooney): Remove this function.
1282- function fixOldExtraState ( extraState : CallPythonFunctionExtraState ) : void {
1283- if ( extraState . otherBlockId ) {
1284- switch ( extraState . functionKind as FunctionKind ) {
1285- case FunctionKind . INSTANCE_WITHIN :
1286- case FunctionKind . INSTANCE_ROBOT :
1287- case FunctionKind . INSTANCE_MECHANISM :
1288- extraState . methodId = extraState . otherBlockId ;
1289- break ;
1290- case FunctionKind . INSTANCE_COMPONENT :
1291- extraState . componentId = extraState . otherBlockId ;
1292- break ;
1293- case FunctionKind . EVENT :
1294- extraState . eventId = extraState . otherBlockId ;
1295- break ;
1296- }
1297- }
1298- if ( extraState . mechanismBlockId ) {
1299- extraState . mechanismId = extraState . mechanismBlockId ;
1300- }
1301- }
0 commit comments