diff options
Diffstat (limited to 'js/app')
-rw-r--r-- | js/app/controllers/feedcontroller.coffee | 9 | ||||
-rw-r--r-- | js/app/directives/translate.coffee | 7 |
2 files changed, 10 insertions, 6 deletions
diff --git a/js/app/controllers/feedcontroller.coffee b/js/app/controllers/feedcontroller.coffee index 07fb22238..6ccc494fa 100644 --- a/js/app/controllers/feedcontroller.coffee +++ b/js/app/controllers/feedcontroller.coffee @@ -54,11 +54,16 @@ ActiveFeed, FeedType, $window) -> # dont do this for other dom elements # the title is some kind of exception since its always there # and it has nothing to do with the body structure + if @_$scope.translations and @_$scope.translations.appName + appName = @_$scope.translations.appName + else + appName = '' + if count > 0 titleCount = @_unreadCountFormatter(count) - title = @_$scope.translations.appName + ' (' + titleCount + ') | ownCloud' + title = appName + ' (' + titleCount + ') | ownCloud' else - title = @_$scope.translations.appName + ' | ownCloud' + title = appName + ' | ownCloud' # only update title when it changed to prevent highlighting the # tab diff --git a/js/app/directives/translate.coffee b/js/app/directives/translate.coffee index c3e2dfd47..29cb8153f 100644 --- a/js/app/directives/translate.coffee +++ b/js/app/directives/translate.coffee @@ -26,7 +26,6 @@ angular.module('News').directive 'newsTranslate', -> directive = restrict: 'E' link: (scope, element, attributes) -> - $element = $(element) - scope.translations or= scope.translations - scope.translations[attributes.key] = $element.text() - $element.remove() + scope.translations = scope.translations || {} + scope.translations[attributes.key] = element.text() + element.remove() |