Cache local instance user on start
This commit is contained in:
parent
1506802c20
commit
2f7a5cbf56
@ -57,7 +57,9 @@ fn init_pool() -> Option<DbPool> {
|
||||
builder = builder.max_size(max_size);
|
||||
};
|
||||
let pool = builder.build(manager).ok()?;
|
||||
Instance::cache_local(&pool.get().unwrap());
|
||||
let conn = pool.get().unwrap();
|
||||
Instance::cache_local(&conn);
|
||||
Instance::cache_local_instance_user(&conn);
|
||||
Some(pool)
|
||||
}
|
||||
|
||||
|
@ -442,6 +442,7 @@ mod tests {
|
||||
)
|
||||
.unwrap();
|
||||
Instance::cache_local(conn);
|
||||
Instance::cache_local_instance_user(conn);
|
||||
instance
|
||||
});
|
||||
let mut user = NewUser::default();
|
||||
|
Loading…
Reference in New Issue
Block a user