From 3b89dd442dab0bf157dfb646dbb44352e7c6d77b Mon Sep 17 00:00:00 2001 From: manatlan Date: Fri, 22 Sep 2023 21:19:07 +0200 Subject: [PATCH] prepare compat for htag > 0.20 --- examples/oauth_example.py | 3 +++ 1 file changed, 3 insertions(+) diff --git a/examples/oauth_example.py b/examples/oauth_example.py index 453d627..804c02b 100644 --- a/examples/oauth_example.py +++ b/examples/oauth_example.py @@ -60,6 +60,7 @@ def user(self): # -> dict or empty dict return self._rootstate.get(OAUTH_SESSION_NAME,{}) def render(self): # dynamic rendering + self.clear() self+= self.title + self.btn if self.user: self.title.set(self.user['name']) @@ -83,6 +84,8 @@ def init(self): self.oa = TagOAuth(self.state) def render(self): # dynamic rendering + self.clear() + self += self.oa self += f"You are {self.oa.user.get('name') or 'unknown'}"