의 미러
https://github.com/friendica/friendica
synced 2025-09-07 21:21:52 +02:00
Add NotFoundException for recipients in api_direct_messages_new()
This commit is contained in:
부모
cb7176ee70
커밋
43688c04b1
1개의 변경된 파일과 9개의 추가작업 그리고 3개의 파일을 삭제
|
@ -3487,14 +3487,20 @@ function api_direct_messages_new($type)
|
|||
dbesc($_POST['screen_name'])
|
||||
);
|
||||
|
||||
// Selecting the id by priority, friendica first
|
||||
api_best_nickname($r);
|
||||
if (DBM::is_result($r)) {
|
||||
// Selecting the id by priority, friendica first
|
||||
api_best_nickname($r);
|
||||
|
||||
$recipient = api_get_user($a, $r[0]['nurl']);
|
||||
$recipient = api_get_user($a, $r[0]['nurl']);
|
||||
}
|
||||
} else {
|
||||
$recipient = api_get_user($a, $_POST['user_id']);
|
||||
}
|
||||
|
||||
if (empty($recipient)) {
|
||||
throw new NotFoundException('Recipient not found');
|
||||
}
|
||||
|
||||
$replyto = '';
|
||||
$sub = '';
|
||||
if (x($_REQUEST, 'replyto')) {
|
||||
|
|
불러오는 중…
테이블 추가
Add a link
Reference in a new issue