yii\mongodb\Session::init PHP Méthode

init() public méthode

This method will initialize the [[db]] property to make sure it refers to a valid MongoDB connection.
public init ( )
    public function init()
    {
        parent::init();
        $this->db = Instance::ensure($this->db, Connection::className());
    }