The apply method optionally takes a high-order function as a argument. This serves as a callback that will be triggered once Colorful has finished it's theme changes
However, ThemeEditor#apply() infers a @NonNull annotation on both of its arguments.
If this is to match the readme, the callback should be optional, and therefore must have a null check before being called.
I believe this will also make things easier for non-Kotlin users to make use of.
The Readme states:
However,
ThemeEditor#apply()
infers a @NonNull annotation on both of its arguments. If this is to match the readme, the callback should be optional, and therefore must have a null check before being called.I believe this will also make things easier for non-Kotlin users to make use of.
Thanks