File tree Expand file tree Collapse file tree 1 file changed +2
-2
lines changed
python/socha/api/networking Expand file tree Collapse file tree 1 file changed +2
-2
lines changed Original file line number Diff line number Diff line change @@ -85,7 +85,7 @@ def handle_move(move_response: _socha.Move) -> Data:
85
85
return Data (class_value = 'eatsalad' )
86
86
elif isinstance (move_response .action , _socha .ExchangeCarrots ):
87
87
exchangeCarrots : _socha .ExchangeCarrots = move_response .action
88
- return Data (class_value = 'exchangecarrots' , value = exchangeCarrots .amount )
88
+ return Data (class_value = 'exchangecarrots' , amount = exchangeCarrots .amount )
89
89
elif isinstance (move_response .action , _socha .FallBack ):
90
90
return Data (class_value = 'fallback' )
91
91
else :
@@ -113,7 +113,7 @@ def create_hare(hare: Hare) -> _socha.Hare:
113
113
carrots = hare .carrots ,
114
114
position = hare .position ,
115
115
last_move = _socha .Move (action = hare .last_action .class_binding )
116
- if hare .last_action
116
+ if hare .last_action and hare . last_action . class_binding
117
117
else None ,
118
118
salads = hare .salads ,
119
119
team = _socha .TeamEnum .One if hare .team == 'ONE' else _socha .TeamEnum .Two ,
You can’t perform that action at this time.
0 commit comments