Questions tagged [pfuser]

The PFUser class is a local representation of a user persisted to the Parse Data.

@interface PFUser : PFObject <PFSubclassing>

The PFUser class is a local representation of a user persisted to the Parse Data. This class is a subclass of a PFObject, and retains the same functionality of a PFObject, but also extends it with various user specific methods, like authentication, signing up, and validation uniqueness.

Many APIs responsible for linking a PFUser with Facebook or Twitter have been deprecated in favor of dedicated utilities for each social network. See PFFacebookUtils, PFTwitterUtils and PFAnonymousUtils for more information.

To find more information :

223 questions
1
vote
3 answers

Trying to Query an object in Parse

query.findObjectsInBackgroundWithBlock { (objects:[AnyObject]?, error:NSError?) -> Void in if error == nil { if let objects = objects as? [PFObject] { for object in objects { print("woot") …
user1990406
  • 519
  • 4
  • 16
1
vote
1 answer

How can I add custom fields to my parse sign up view controller on swift

Could you guys help? Im trying to add couple custom fields to my sign up form but I don't really know how to. I would like to add a company, name, phone, address and website field. this is my code on my signUpViewController thanks heaps import…
1
vote
1 answer

s ParseUser.CurrentUser() different on Parses servers from Client Side

While working with objects, I am trying to compare one field of a queried object to the current user using the app I was using an IF loop if( ParseUser.CurrentUser() == object.getString("User")) { Do this } However, ParseUser.CurrentUser does not…
jac1008
  • 11
  • 1
1
vote
2 answers

PFUser currentUser returns nil after restarting app

I'm working on a swift iPhone application using Parse for the backend and when I restart the app the currentUser isn't recognized and returns nil redirecting to the login page. Once I sign back in the user stays logged in until I stop the app. if…
nviens
  • 427
  • 2
  • 4
  • 18
1
vote
2 answers

Parse..com cloud code: Trying to update user's column but nothing happens

i have a background job that is trying to update user balance with a new balance if they won the league This functions are helper functions which are being called properly but "query.first" in updateUserEarnings function and "then" function inside…
Asif Alamgir
  • 1,454
  • 1
  • 16
  • 41
1
vote
1 answer

Smart-search for Parse Usernames in Swift not working

I'm trying to have a smart-search in my iOS app so that when a user types a character into a UISearchBar, the results automatically update in the tableview below the searchbar. For some reason, the searchBar function with textDidChange isn't called…
Petruc
  • 23
  • 4
1
vote
2 answers

Swift: '(String) -> AnyObject?' does not have a member named 'subscript'

I am trying to convert a PFUser (from Parse.com) to a dictionary of [String : AnyObject] type, but I got the following error that seems very confusing to me. I did google search and found the following two SO questions, which, however, still not…
TonyW
  • 18,375
  • 42
  • 110
  • 183
1
vote
1 answer

How can I import my data from Parse? I would like to import data from a user class other than the class

var users = [""] // This is a temporary Array for storing the data from Parse. @IBOutlet var messageTableView: UITableView! // The TableView will output the data in the array. override func viewDidLoad() { super.viewDidLoad() var query =…
1
vote
0 answers

Saving PFObject throws exception

I have defined my own class MYPFObject to wrap a PFObject with all the apis like saveInbackground methods directing it to internal PFObject's saveinbackground. This is to decouple my Parse code from rest of my code into one model layer. The [PFUser…
1
vote
0 answers

Overriding a property for the subclassed PFUser - swift

I have successfully subclassed the PFUser. PFUser has username and email properties. What I would like to do is, accept an email for the username, and when the username is set, set the email property to username as well. So I am trying to override…
oyalhi
  • 3,834
  • 4
  • 40
  • 45
1
vote
2 answers

Add column to PFUser AFTER signup? Parse, Swift

I would like my user to add/edit details about their profile after they register with my app. @IBAction func doneEditting(sender: AnyObject) { self.completeEdit() } func completeEdit() { var user = PFUser() user["location"] =…
ishkur88
  • 1,265
  • 2
  • 9
  • 12
1
vote
1 answer

PFUser currentUser saveInBackgroundWithBlock completes succeeded without even trying

I am trying to alter the logged in user. I make my changes as usual, and I call: [[PFUser currentUser] saveInBackgroundWithBlock:^(BOOL succeeded, NSError *PF_NULLABLE_S error){ if(succeeded){ NSLog(@"Saved user successfully."); …
Can Poyrazoğlu
  • 33,241
  • 48
  • 191
  • 389
1
vote
1 answer

Parse cloud code relations query

I'm trying to query whether a PFUser exists in another PFUser's 'blockedUsers' relation column before sending a push notification: I have written this but it doesn't seem to be working: var recipientBlockList = toUser.relation("blockedUsers"); var…
Halpo
  • 2,982
  • 3
  • 25
  • 54
1
vote
1 answer

How to pass auth token from Parse SDK to Fabric TwitterKit?

I log in my Twitter users using +[PFTwitterUtils loginWithBlock:] method from Parse SDK. To get user profile picture I login second time with -[Twitter logInWithCompletion:] method from Fabric TwitterKit. Is there any way to pass auth token from…
Alexander Vasenin
  • 11,437
  • 4
  • 42
  • 70
1
vote
0 answers

PFUser.logInWithUsernameInBackground does not work in Parse 1.7.4

I am trying to log in the user using the captured credentials from my username & password fields. My code inside an IBAction (of a button) is the following: PFUser.logInWithUsernameInBackground("Test", password: "123123"){…
idelara
  • 1,786
  • 4
  • 24
  • 48