Add logging for avatar processing
This commit is contained in:
parent
a8d3f59abd
commit
4f27a39ace
2 changed files with 16 additions and 0 deletions
|
@ -139,6 +139,12 @@ class Edit extends Profile
|
|||
|
||||
if (true === $result) {
|
||||
$this->curUser->avatar = $v->upload_avatar->name() . '.' . $v->upload_avatar->ext();
|
||||
} else {
|
||||
$this->c->Log->warning('Profile Failed image processing', [
|
||||
'user' => $this->user->fLog(),
|
||||
'curUser' => $this->curUser->fLog(),
|
||||
'error' => $v->upload_avatar->error(),
|
||||
]);
|
||||
}
|
||||
}
|
||||
|
||||
|
|
|
@ -135,7 +135,17 @@ class RegLog extends Page
|
|||
|
||||
if (true === $result) {
|
||||
$user->avatar = $image->name() . '.' . $image->ext();
|
||||
} else {
|
||||
$this->c->Log->warning('OAuth Failed image processing', [
|
||||
'user' => $user->fLog(),
|
||||
'error' => $image->error(),
|
||||
]);
|
||||
}
|
||||
} else {
|
||||
$this->c->Log->warning('OAuth Avatar not image', [
|
||||
'user' => $user->fLog(),
|
||||
'error' => $this->c->Files->error(),
|
||||
]);
|
||||
}
|
||||
}
|
||||
|
||||
|
|
Loading…
Add table
Reference in a new issue