title: CakePhp 2.x - plugin model is not being loaded
body: <p>I a making a plugin in CakePhp and I am using multiple models inside the plugin. I created those models by using the console and baked them. I ran into a problem when using 1 of them and it only appears with this specific model.</p>
  
  <p>The model file name:<br>
  <strong>GamificationBadgeUnlockActionProgression.php</strong></p>
  
  <p>Content of model:</p>
  
  <pre><code>&lt;?php
      App::uses('GamificationAppModel', 'Gamification.Model');
  
      class GamificationBadgeUnlockActionProgression extends GamificationAppModel {
  
      function __construct() {
          parent::__construct();
          echo 'oleej';
          exit;
      }
  
      public $belongsTo = array(
          'GamificationBadgeProgression' =&gt; array(
              'className' =&gt; 'GamificationBadgeProgression',
              'foreignKey' =&gt; 'gamification_badge_progression_id'
          ),
          'GamificationBadgeUnlockAction' =&gt; array(
              'className' =&gt; 'GamificationBadgeUnlockAction',
              'foreignKey' =&gt; 'gamification_badge_unlock_action_id'
          )
      );
  
      public function addMissingProgression($missingProgression)
      {
          /*$this-&gt;saveMany($missingProgression, array(
              'fieldlist' =&gt; array('gamification_badge_progression_id', 'gamification_badge_unlock_action_id')
          ));*/
      }
  }
  </code></pre>
  
  <p>In the controller of the plugin I have:  </p>
  
  <pre><code>public $uses = array('Gamification.GamificationBadge',
      'Gamification.GamificationBadgeProgression', 
      'Gamification.GamificationBadgeUnlockAction',
      'Gamification.GamificationBadgeUnlockActionProgression', 
      'Gamification.GamificationBadgeUnlockType');
  </code></pre>
  
  <p>All the other models are being loaded, except 'Gamification.GamificationBadgeUnlockActionProgression'. Which is very weird. It has all required stuff and it follows the naming conventions and everything.
  It just isn't being loaded as the constructor is never called and the echo is never shown.</p>
  
  <p>When I call the function from the model like this with an array as parameter:</p>
  
  <pre><code>    $this-&gt;GamificationBadgeUnlockActionProgression-&gt;addMissingProgression($missingProgression);
  </code></pre>
  
  <p>Then I get an error</p>
  
  <pre><code>SQLSTATE[42000]: Syntax error or access violation: 1064 You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near 'addMissingProgression' at line 1
  </code></pre>
  
  <p>Because the model is not loaded.<br>
  However CakePhp does create a magic model with the same name, which results in the error above, because the model magically excists but the function ofcourse doesnt and neither do the relations.</p>
  
  <p>What am I missing here?</p>