Don't crash on concurrent consent given
commitc9c4ce728e201ff973f6084d280a22adb795cc5d
authorMagnus Hagander <magnus@hagander.net>
Fri, 8 Jun 2018 10:45:52 +0000 (8 12:45 +0200)
committerMagnus Hagander <magnus@hagander.net>
Fri, 8 Jun 2018 10:45:52 +0000 (8 12:45 +0200)
tree085b0eceab7522adab76590e26f43cf09efaa7d1
parentb47c801958a5e36782016f5ed6791b32dfce9f93
Don't crash on concurrent consent given

If a user gave consent to sharing community auth data in two parallel
sessions, one of them would crash with a unique violation. To avoid
that, use the django function for get_or_create(), and just throw away
the results if it turned out to be a get.
pgweb/account/views.py