Пример #1
0
 def func_wrapper(self, *args, **kwargs):
     if not self.was_login_executed:
         raise LoginRequired('Use login method first')
     else:
         return func(self, *args, **kwargs)
Пример #2
0
 def func_wrapper(self, *args, **kwargs):
     if not self.was_login_executed:
         raise LoginRequired('请先登录!')
     else:
         return func(self, *args, **kwargs)