@@ -204,7 +204,7 @@ public final class StateMachine<S: StateType, E: EventType>: Machine<S, E>
204204
205205 let _routeID = _RouteID ( event: Optional< Event< E>>. None, transition: transition, key: key)
206206
207- return ActionDisposable . init { [ weak self] in
207+ return ActionDisposable { [ weak self] in
208208 self ? . _removeRoute ( _routeID)
209209 }
210210 }
@@ -230,7 +230,7 @@ public final class StateMachine<S: StateType, E: EventType>: Machine<S, E>
230230 }
231231 }
232232
233- return ActionDisposable . init {
233+ return ActionDisposable {
234234 routeDisposable. dispose ( )
235235 handlerDisposable. dispose ( )
236236 }
@@ -285,7 +285,7 @@ public final class StateMachine<S: StateType, E: EventType>: Machine<S, E>
285285
286286 let handlerID = _HandlerID < S , E > ( event: nil , transition: transition, key: key)
287287
288- return ActionDisposable . init { [ weak self] in
288+ return ActionDisposable { [ weak self] in
289289 self ? . _removeHandler ( handlerID)
290290 }
291291 }
@@ -330,7 +330,7 @@ public final class StateMachine<S: StateType, E: EventType>: Machine<S, E>
330330 let routeDisposables = chain. routes. map { self . addRoute ( $0) }
331331 let handlerDisposable = self . addChainHandler ( chain, handler: handler)
332332
333- return ActionDisposable . init {
333+ return ActionDisposable {
334334 routeDisposables. forEach { $0. dispose ( ) }
335335 handlerDisposable. dispose ( )
336336 }
@@ -433,7 +433,7 @@ public final class StateMachine<S: StateType, E: EventType>: Machine<S, E>
433433 }
434434 handlerDisposables += [ handlerDisposable]
435435
436- return ActionDisposable . init {
436+ return ActionDisposable {
437437 handlerDisposables. forEach { $0. dispose ( ) }
438438 }
439439 }
@@ -452,7 +452,7 @@ public final class StateMachine<S: StateType, E: EventType>: Machine<S, E>
452452
453453 let routeMappingID = _RouteMappingID ( key: key)
454454
455- return ActionDisposable . init { [ weak self] in
455+ return ActionDisposable { [ weak self] in
456456 self ? . _removeStateRouteMapping ( routeMappingID)
457457 }
458458 }
@@ -476,7 +476,7 @@ public final class StateMachine<S: StateType, E: EventType>: Machine<S, E>
476476 handler ( context)
477477 }
478478
479- return ActionDisposable . init {
479+ return ActionDisposable {
480480 routeDisposable. dispose ( )
481481 handlerDisposable. dispose ( )
482482 }
0 commit comments