title: Strict Standards: Non-static method dbInstance::getInstance()
body: <p>I can't figure out why this error in php 5.4.</p>
  
  <p><strong>Strict Standards: Non-static method dbInstance::getInstance() should not be called statically</strong></p>
  
  <p>The class is:</p>
  
  <pre><code>class dbInstance
  {
      private static $db;
  
      public static function getInstance()
      {
          if (! self::$db) self::$db = new db();
          return self::$db;
      }
  }
  </code></pre>
  
  <p>I call it like:</p>
  
  <pre><code> $registry-&gt;db = $db = dbInstance::getInstance()
  </code></pre>
  
  <p>Thanks</p>