Closed Somojojojo closed 7 years ago
Hmm, I forked the project to try and figure the issue out. Even after instantiating the VC with an ID, it still throws an error... XCode 8 and Swift 3. Early adopter pains.
I'll comment again if I figure anything out, and submit a PR if I fix it.
EDIT: Inspecting the bundle
variable, this is the output:
NSBundle </Users/~~my user~~/Library/Developer/CoreSimulator/Devices/88E597EC-F3C8-43F3-A743-19C38C746FC4/data/Containers/Bundle/Application/8EA6A8B5-D6D9-4447-894A-AF20EF676134/projectname.app/Frameworks/WWCalendarTimeSelector.framework/WWCalendarTimeSelectorStoryboardBundle.bundle> (not yet loaded)
EDIT 2: Adding WWCalendarTimeSelector as the module in the storyboard file fixes the instantiate method, but now the lib is crashing when setting the delegate of clockView to self.
Hi, you can goto the storyboard and remove the modules from the uiviewcontrollers and one of the custom uiview. It should fix the errors. I'm having issues pushing onto cocoapods to update my library as well lol
apologies for the issues!
I assume you meant to add the module to the main UIViewController and the WWClock UIView? That fixed the issue completely. Thanks for your help, @weilsonwonder :) Are you going to put that change into your repo, or do you want a PR?
Line 606 of WWCalendarTimeSelector.swift:
let picker = UIStoryboard(name: "WWCalendarTimeSelector", bundle: bundle).instantiateInitialViewController() as! WWCalendarTimeSelector
I've refactored my code to instantiate each time the selector is needed, and this error still comes up.
Can anybody else reproduce this? It happens when calling
WWCalendarTimeSelector.instantiate()