##// END OF EJS Templates
notifications: skip fetching of settings in notifications....
marcink -
r1497:1047cf00 default
parent child Browse files
Show More
@@ -324,24 +324,15 b' class EmailNotificationModel(BaseModel):'
324
324
325 """
325 """
326 super(EmailNotificationModel, self).__init__()
326 super(EmailNotificationModel, self).__init__()
327 self.rhodecode_instance_name = None
327 self.rhodecode_instance_name = rhodecode.CONFIG.get('rhodecode_title')
328
328
329 def _update_kwargs_for_render(self, kwargs):
329 def _update_kwargs_for_render(self, kwargs):
330 """
330 """
331 Inject params required for Mako rendering
331 Inject params required for Mako rendering
332
332
333 :param kwargs:
333 :param kwargs:
334 :return:
335 """
334 """
336 rhodecode_name = self.rhodecode_instance_name
335 kwargs['rhodecode_instance_name'] = self.rhodecode_instance_name
337 if not rhodecode_name:
338 try:
339 rc_config = SettingsModel().get_all_settings()
340 except Exception:
341 log.exception('failed to fetch settings')
342 rc_config = {}
343 rhodecode_name = rc_config.get('rhodecode_title', '')
344 kwargs['rhodecode_instance_name'] = rhodecode_name
345
336
346 _kwargs = {
337 _kwargs = {
347 'instance_url': h.url('home', qualified=True),
338 'instance_url': h.url('home', qualified=True),
General Comments 0
You need to be logged in to leave comments. Login now