Skip to content

Commit

Permalink
Merge pull request #4622 from ewdl/fix-popover-override
Browse files Browse the repository at this point in the history
Prevent the popover options to be overwritten (fix #3173)
  • Loading branch information
mlynch committed Dec 6, 2015
2 parents 4d8069b + 44460d7 commit dbd0d24
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions js/angular/service/popover.js
Original file line number Diff line number Diff line change
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 dbd0d24

Please sign in to comment.