Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Error: use of unresolved identifier dataFromNetworking #82

Closed
NielsvanDijk opened this issue Oct 22, 2014 · 1 comment
Closed

Error: use of unresolved identifier dataFromNetworking #82

NielsvanDijk opened this issue Oct 22, 2014 · 1 comment

Comments

@NielsvanDijk
Copy link

Hii,

Ik have a question :) what do i wrong here? i get the error:

"use of unresolved identifier dataFromNetworking"

This is my code

Alamofire.request(.GET, "http://www.pasveer.nl/api/get_posts")
.responseJSON { (_, _, JSON, _) in

    let json = JSON(data: dataFromNetworking)
    if let userName = json[0]["user"]["name"].string{
        println(userName)
    else{
        //something else
    }
}

What am i doing wrong?

@LukeTangPL
Copy link
Member

Sorry @NielsvanDijk your wrong. The JSON in Alamofire as AnyObject not SwiftJSON's JSON.Alamofire-SwiftyJSON may help you.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants