From fe9f43d17f11263e64a0168cabce28b8365fe9a8 Mon Sep 17 00:00:00 2001 From: Adam Bradley <adambradley25@gmail.com> Date: Tue, 16 Sep 2014 10:23:49 -0500 Subject: [PATCH] fix(titles): error during quick transition changes --- js/angular/controller/navBarController.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/js/angular/controller/navBarController.js b/js/angular/controller/navBarController.js index c5cfc61012c..219cac5c86f 100644 --- a/js/angular/controller/navBarController.js +++ b/js/angular/controller/navBarController.js @@ -103,7 +103,7 @@ function($scope, $element, $attrs, $ionicViewService, $animate, $compile, $ionic currentTitles = $element[0].querySelectorAll('.title'); if (currentTitles.length) { oldTitleEl = $compile('<h1 class="title" ng-bind-html="oldTitle"></h1>')($scope); - jqLite(currentTitles[0]).replaceWith(oldTitleEl); + jqLite(currentTitles[currentTitles.length-1]).replaceWith(oldTitleEl); } //Compile new title newTitleEl = $compile('<h1 class="title invisible" ng-bind-html="title"></h1>')($scope);