equal
deleted
inserted
replaced
1215 |
1215 |
1216 def prefered_language(self, language=None): |
1216 def prefered_language(self, language=None): |
1217 # mock CWUser.prefered_language, mainly for testing purpose |
1217 # mock CWUser.prefered_language, mainly for testing purpose |
1218 return self.property_value('ui.language') |
1218 return self.property_value('ui.language') |
1219 |
1219 |
|
1220 # CWUser compat for notification ########################################### |
|
1221 |
|
1222 def name(self): |
|
1223 return 'cubicweb' |
|
1224 |
|
1225 class _IEmailable: |
|
1226 @staticmethod |
|
1227 def get_email(): |
|
1228 return '' |
|
1229 |
|
1230 def cw_adapt_to(self, iface): |
|
1231 if iface == 'IEmailable': |
|
1232 return self._IEmailable |
|
1233 return None |
|
1234 |
1220 from logging import getLogger |
1235 from logging import getLogger |
1221 from cubicweb import set_log_methods |
1236 from cubicweb import set_log_methods |
1222 set_log_methods(Session, getLogger('cubicweb.session')) |
1237 set_log_methods(Session, getLogger('cubicweb.session')) |