From cc1e4a3629e16d8d68c55e07c9e99c92c5814549 Mon Sep 17 00:00:00 2001 From: neodarz Date: Sun, 12 Apr 2020 10:25:23 +0200 Subject: Add a function to force the refresh of the OAuth2 token --- pyfunkwhale/client.py | 7 +++++++ 1 file changed, 7 insertions(+) (limited to 'pyfunkwhale/client.py') diff --git a/pyfunkwhale/client.py b/pyfunkwhale/client.py index cf19673..c6ef1f2 100644 --- a/pyfunkwhale/client.py +++ b/pyfunkwhale/client.py @@ -76,6 +76,13 @@ class Client(object): self._get_token() write_file(self.token_filename, self.token) + def _force_refresh_token(self): + """ + Force the refresh of the OAuth2 token + """ + self._get_token() + write_file(self.token_filename, self.token) + def _get_JWT_token(self): """ Get a JWT token. -- cgit v1.2.1