Für Auth*-Models eigene Datenbankverbindung nutzen
[kivitendo-erp.git] / SL / DB / Object.pm
index f138518..52b9300 100644 (file)
@@ -25,7 +25,7 @@ sub new {
 sub init_db {
   my $class_or_self = shift;
   my $class         = ref($class_or_self) || $class_or_self;
-  my $type          = 'LXOFFICE';
+  my $type          = $class =~ m/::Auth/ ? 'LXOFFICE_AUTH' : 'LXOFFICE';
 
   return SL::DB::create(undef, $type);
 }