Open windbender opened 7 years ago
+1
as a work around you can inject $confirmModalDefaults, along side $confirm, select the template, and set it on the settings object.
$confirm( {text:'Confirm Delete',ok:'Yes Delete',cancel:'Cancel'} ,{template: $confirmModalDefaults.additionalTemplates['dangerTemplate'].template})
The code as it sits ends up deleting a template ( because it's trying to use templateUrl )
This is because the check which is supposed to confirm existence of templateUrl is code in correctly. Specifically line 63 checkout for 'templateUrl' in settings which returns true even if the field has a value of undefined. A more appropriate check would be just settings.templateUrl which will return false in the case of undefined