summaryrefslogtreecommitdiffstats
path: root/gitsrht/service.py
diff options
context:
space:
mode:
Diffstat (limited to 'gitsrht/service.py')
-rw-r--r--gitsrht/service.py1
1 files changed, 1 insertions, 0 deletions
diff --git a/gitsrht/service.py b/gitsrht/service.py
index 9e0ed86..d73f4ad 100644
--- a/gitsrht/service.py
+++ b/gitsrht/service.py
@@ -50,6 +50,7 @@ class GitOAuthService(AbstractOAuthService):
def lookup_or_register(self, token, token_expires, scopes):
user = super().lookup_or_register(token, token_expires, scopes)
+ db.session.flush()
keys_url = f"{meta_origin}/api/user/ssh-keys"
for key in get_results(keys_url, user.oauth_token):
self.ensure_user_sshkey(user, key)