title: Angular uibModal, Resolve, Unknown Provider
body: <p>I am trying to expose a "generic" modal - using Angular's <a href="https://angular-ui.github.io/bootstrap/#/modal" rel="noreferrer">$uibModal</a> - through a service. Here is the definition of that service:</p>
  
  <pre><code>angular.module('app').service('CustomModalService', ['$uibModal', function ($uibModal) {
  
      var openCustomModal = function (size, title, message) {
          var actionToPerformOnConfirm = action;
  
          var modalInstance = $uibModal.open({
              templateUrl : 'templates/CustomModal.html',
              size: size,
              resolve: {
                  title: title,
                  message: message
              }
          });
      };
  
      return {
          openCustomModal: openCustomModal
      };
  }]);
  </code></pre>
  
  <p>Nothing too complicated, above. However, it is not working. If I remove the <code>resolve</code> property from the object, the service works; however, if I include the <code>resolve</code> property, I get the <a href="https://docs.angularjs.org/error/$injector/unpr" rel="noreferrer">Unknown Provider</a> error originating from that property.</p>
  
  <p>The documentation for the <code>resolve</code> property reads: </p>
  
  <blockquote>
    <p>(Type: Object) - Members that will be resolved and passed to the
    controller as locals; it is equivalent of the resolve property in the
    router.</p>
  </blockquote>
  
  <p>The objective is to be able to provide a template for the modal that utilizes these properties in its DOM, e.g. :</p>
  
  <pre><code>&lt;div ng-controller="CustomModalController"&gt;
      &lt;div class="modal-header"&gt;
          &lt;h3 class="modal-title"&gt;{{title}}&lt;/h3&gt;
      &lt;/div&gt;
      &lt;div class="modal-body"&gt;
          {{message}}
      &lt;/div&gt;
      &lt;div class="modal-footer"&gt;
          &lt;button class="ad-button ad-blue" type="button" ng-click="confirmAction()"&gt;&lt;/button&gt;
          &lt;button class="ad-button ad-blue" type="button" ng-click="cancelAction()"&gt;&lt;/button&gt;
      &lt;/div&gt;
  &lt;/div&gt;
  </code></pre>
  
  <p>What am I missing that is causing this error to be thrown?</p>