mamaral / Onboard

An iOS framework to easily create a beautiful and engaging onboarding experience with only a few lines of code.
MIT License
6.46k stars 764 forks source link

Must unwrap page instances in Swift #154

Closed phatmann closed 7 years ago

phatmann commented 7 years ago

Fixes issue #150

mamaral commented 7 years ago

Is there more coming?

mamaral commented 7 years ago

Oh... looks like the code is OK?

phatmann commented 7 years ago

That's it! The user has to force unwrap the page instance optionals. No changes in library code needed.

phatmann commented 7 years ago

Ah, a better fix is to annotate your initializers to indicate they cannot fail.

phatmann commented 7 years ago

Change your initializers to have nonnull annotation. For example, - (nonnull instancetype)initWithContents:...

phatmann commented 7 years ago

I will modify the PR accordingly.

phatmann commented 7 years ago

Don't merge this yet. For some reason the initializers are still marked as failable. Debugging now.

phatmann commented 7 years ago

All good, merge away!

mamaral commented 7 years ago

👍