Mod login methods of namiUser

This commit is contained in:
philipp lang 2021-04-10 00:28:27 +02:00
parent a785e839b2
commit 068c6b3cb8
1 changed files with 2 additions and 6 deletions

View File

@ -20,15 +20,11 @@ class NamiUser implements Authenticatable {
} }
public function getNamiApi() { public function getNamiApi() {
return app(Api::class)->setUser($this)->login( return $this->attemptNamiLogin(cache('member.'.$this->mglnr)['credentials']['password']);
$this->mglnr,
cache('member.'.$this->mglnr)['credentials']['password'],
$this->groupid
);
} }
public function attemptNamiLogin($password) { public function attemptNamiLogin($password) {
return Nami::setUser($this)->login($this->mglnr, $password, $this->groupid); return Nami::login($this->mglnr, $password, $this->groupid);
} }
public function getNamiGroupId() { public function getNamiGroupId() {