Skip to content

Commit

Permalink
Prevent the popover options to be overwritten (fix #3173)
Browse files Browse the repository at this point in the history
  • Loading branch information
Alexandre Laurent committed Nov 11, 2015
1 parent 3adb7fc commit 44460d7
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions js/angular/service/popover.js
Expand Up @@ -204,7 +204,7 @@ function($ionicModal, $ionicPosition, $document, $window) {
* controller (ionicPopover is built on top of $ionicPopover).
*/
fromTemplate: function(templateString, options) {
return $ionicModal.fromTemplate(templateString, ionic.Utils.extend(POPOVER_OPTIONS, options || {}));
return $ionicModal.fromTemplate(templateString, ionic.Utils.extend({}, POPOVER_OPTIONS, options));
},
/**
* @ngdoc method
Expand All @@ -215,7 +215,7 @@ function($ionicModal, $ionicPosition, $document, $window) {
* an {@link ionic.controller:ionicPopover} controller (ionicPopover is built on top of $ionicPopover).
*/
fromTemplateUrl: function(url, options) {
return $ionicModal.fromTemplateUrl(url, ionic.Utils.extend(POPOVER_OPTIONS, options || {}));
return $ionicModal.fromTemplateUrl(url, ionic.Utils.extend({}, POPOVER_OPTIONS, options));
}
};

Expand Down

0 comments on commit 44460d7

Please sign in to comment.