function api_direct_messages_box($type, $box, $verbose)
{
$a = get_app();
-
+ if (api_user() === false) {
+ throw new ForbiddenException();
+ }
// params
$count = (x($_GET, 'count') ? $_GET['count'] : 20);
$page = (x($_REQUEST, 'page') ? $_REQUEST['page'] -1 : 0);
unset($_GET["screen_name"]);
$user_info = api_get_user($a);
- if (api_user() === false || $user_info === false) {
+ if ($user_info === false) {
throw new ForbiddenException();
}
$profile_url = $user_info["url"];