(()=>{function e(n){return{restrict:"A",require:"ngModel",scope:{template:"=c8ySmartRestValidateUniqueMsgIdInTemplate",originalMsgId:"=originalMsgId"},link:function(i,e,t,a){a.$validators.uniqueMsgIdInTemplate=function(e,t){e=e||t,t=i.template&&n.getAllMsgIds(i.template),t=_.without(t,i.originalMsgId);return i.template&&e&&!_.includes(t,e)}}}}e.$inject=["c8ySmartRestTemplates"],angular.module("c8y.smartRestEditor").directive("c8ySmartRestValidateUniqueMsgIdInTemplate",e)})();