[DALICORE-70] How should the user fields be updated during a network connect Created: 14/Sep/12  Updated: 02/Oct/12  Resolved: 02/Oct/12

Status: Closed
Project: dalicore
Component/s: dalicore-social
Affects Version/s: None
Fix Version/s: 0.9.14

Type: Improvement Priority: Major
Reporter: Joeri Sykora Assignee: Unassigned
Resolution: Fixed Votes: 0
Labels: None
Remaining Estimate: Not Specified
Time Spent: Not Specified
Original Estimate: Not Specified


When you connect to an external network anonymously (without specifying an existing user uid), a new user object will be created for you and the fields firstName, lastName and depiction will be set from the available information from the external network. However, when you connect to an external network through an existing user, those user fields will never be updated. In most cases, this is probably the best solution, but sometimes you would like DaliCoreSocial to update the user fields regardless. This is currently not possible.

Comment by Joeri Sykora [ 14/Sep/12 ]

The easiest solution for now, would be to add an optional boolean query parameter "update" which defaults to false. When the value of the parameter is true, then the available information from the external network that we are connecting to will be stored in the fields of the provided user.

Comment by johanvos [ 17/Sep/12 ]

That should work.
Apart from that, different social networks maintain different bits of information. I think it makes sense to have a method that allows to "update" user parameters with information in a specific social network. E.g. take my picture from Facebook, and my last name from Twitter.
But this is post-connect behaviour. We should keep the connect method as simple as possible (adding the optional boolean "update" query is fine), and allow for more fine-grained update outside the connect method.

Comment by Joeri Sykora [ 02/Oct/12 ]

Added the query parameter with name "update" to the connect methods, which should contain either "true" or "false". The default value when the parameter is not provided is "false".

When the user already exists and is being connected to an external network it did not yet connect to and the value of the "update" parameter is "true", then the first name, the last name, the screen name and the depiction of the user will be updated with the information provided by the new external the user is being connected to.

Comment by Joeri Sykora [ 02/Oct/12 ]

Release 0.9.14

Generated at Tue Oct 25 00:04:41 UTC 2016 using JIRA 6.2.3#6260-sha1:63ef1d6dac3f4f4d7db4c1effd405ba38ccdc558.