appinioGmbH / flutter_packages

Dart and Flutter plugins/packages used and maintained by @appinioGmbH
187 stars 214 forks source link

[appinio_swiper] Add direction to emptyFunctionIndex #29

Closed SEGVeenstra closed 1 year ago

SEGVeenstra commented 1 year ago

Issue

The emptyFunctionIndex that is used when no onSwipe callback is provided is missing the direction parameter. This will throw a NoSuchMethodError:

The following NoSuchMethodError was thrown while notifying status listeners for AnimationController:
Closure call with mismatched arguments: function 'emptyFunctionIndex'
Receiver: Closure: (int, AppinioSwiperDirection) => void from Function 'emptyFunctionIndex': static.
Tried calling: emptyFunctionIndex(3, Instance of 'AppinioSwiperDirection')

Solution

This PR will add the missing parameter.