@@ -1284,15 +1284,20 @@ def __init__(self, *args, **kwargs):
12841284 if len (args ) == 1 and len (kwargs ) == 0 :
12851285 kwargs = args [0 ]
12861286
1287+ if kwargs .get ("new_price" ):
1288+ new_price = Optional (Price (kwargs ["new_price" ]))
1289+ else :
1290+ new_price = Optional (None )
1291+
12871292 if kwargs .get ("delta_amount_to_sell" ):
12881293 delta_amount_to_sell = Optional (Asset (kwargs ["delta_amount_to_sell" ]))
12891294 else :
12901295 delta_amount_to_sell = Optional (None )
12911296
1292- if kwargs .get ("new_price " ):
1293- new_price = Optional (Price (kwargs ["new_price " ]))
1297+ if kwargs .get ("new_expiration " ):
1298+ new_expiration = Optional (PointInTime (kwargs ["new_expiration " ]))
12941299 else :
1295- new_price = Optional (None )
1300+ new_expiration = Optional (None )
12961301
12971302 if kwargs .get ("on_fill" ):
12981303 on_fill = Optional (Array ([LimitOrderAutoAction (o ) for o in kwargs ["on_fill" ]])),
@@ -1307,7 +1312,7 @@ def __init__(self, *args, **kwargs):
13071312 ("order" , ObjectId (kwargs ["order" ], "limit_order" )),
13081313 ("new_price" , new_price ),
13091314 ("delta_amount_to_sell" , delta_amount_to_sell ),
1310- ("new_expiration" , Optional ( None ) ),
1315+ ("new_expiration" , new_expiration ),
13111316 ("on_fill" , on_fill ),
13121317 ("extensions" , Set ([])),
13131318 ]
0 commit comments