I got this error 'Cannot call value of non-function type 'module<Firebase>'' The code is copied from a tutorial sample project. But no errors in the sample project. The
sample project moved from Xcode 7 to 8 and I had chaged the syntax before copy. What is my problem? I will be very appreciate if anyone helped my. Thanks
fileprivate var _BASE_REF = Firebase(url: "\(BASE_URL)")//error here
fileprivate var _USER_REF = Firebase(url: "\(BASE_URL)/users")//error here
fileprivate var _JOKE_REF = Firebase(url: "\(BASE_URL)/jokes")//error here
var BASE_REF: Firebase {// another error: Use of undeclared identifier type 'Firebase'
return _BASE_REF!
}
var USER_REF: Firebase {// another error: Use of undeclared identifier type 'Firebase'
return _USER_REF!
}
var CURRENT_USER_REF: Firebase {// another error: Use of undeclared identifier type 'Firebase'
let userID = UserDefaults.standard.value(forKey: "uid") as! String
let currentUser = Firebase(url: "\(BASE_REF)").child(byAppendingPath: "users").child(byAppendingPath: userID)
return currentUser!
}
var JOKE_REF: Firebase {// another error: Use of undeclared identifier type 'Firebase'
return _JOKE_REF!
}