ios - Why is fatal error: unexpectedly found nil while unwrapping an Optional value (lldb) occurring? -


an error occurring in swift app ios 8 in xcode 6.4.

fatal error: unexpectedly found nil while unwrapping optional value (lldb)

gyazo screenshot: http://i.gyazo.com/6bd9207655763cf941b44c8049f88549.png

i've been trying fix error 2 hours now!

please me.

thanks,

jamie mathieson

well, that's simple problem solve.. usernametextfield.text , passwordtextfield.text can blank, can't put ! after it.. have this:

if usernametextfield.text != nil && passwordtextfield != nil { user.username = usernametextfield.text user.password = passwordtextfield.text }

hope helps..


Comments

Popular posts from this blog

yii2 - Yii 2 Running a Cron in the basic template -

asp.net - 'System.Web.HttpContext' does not contain a definition for 'GetOwinContext' Mystery -

mercurial graft feature, can it copy? -