File tree Expand file tree Collapse file tree 3 files changed +19
-12
lines changed Expand file tree Collapse file tree 3 files changed +19
-12
lines changed Original file line number Diff line number Diff line change @@ -2,6 +2,7 @@ unique_ids:
22 forms : {}
33 modules :
44 _demo_startup : ' 1719087683748644303970981.0312'
5+ _users : ' 1721065127336894381056321.5935'
56 auto_batch : ' 1720557189347558051799744.9072'
67 tables : ' 1720711436314890422194670.1993'
78 tables._tables : ' 1721062590178633669568195.047'
Original file line number Diff line number Diff line change 1+ from .auto_batch import debatchify_inputs , BatchTable
2+ import anvil .users
3+
4+
5+ def force_login (* args , ** kwargs ):
6+ return debatchify_inputs (anvil .users .force_login )(* args , ** kwargs )
7+
8+
9+ def get_user (* args , ** kwargs ):
10+ user_row = anvil .users .get_user (* args , ** kwargs )
11+ batch_table = BatchTable .of_row (user_row )
12+ return batch_table .get_batch_row (user_row )
Original file line number Diff line number Diff line change 1- from .auto_batch import debatchify_inputs , BatchTable
1+ from .auto_batch import USE_WRAPPED
2+ from . import _users
23import anvil .users
34
45
5- def force_login (* args , ** kwargs ):
6- return debatchify_inputs (anvil .users .force_login )(* args , ** kwargs )
7-
8-
9- def get_user (* args , ** kwargs ):
10- user_row = anvil .users .get_user (* args , ** kwargs )
11- batch_table = BatchTable .of_row (user_row )
12- return batch_table .get_batch_row (user_row )
13-
14-
156def __getattr__ (attr ):
16- return getattr (anvil .users , attr )
7+ if USE_WRAPPED and attr in ('force_login' , 'get_user' ):
8+ return getattr (_users , attr )
9+ else :
10+ return getattr (anvil .users , attr )
You can’t perform that action at this time.
0 commit comments