public static function delete($request, $match)
    {
        // Check access
        if(isset($match['userId'])){
            $user = Pluf_Shortcuts_GetObjectOr404('User_Account', $match['userId']);
        }else{
            $user = $request->user;
        }
        $profile = null;
        if (array_key_exists('profileId', $match)) {
            $profile = Pluf_Shortcuts_GetObjectOr404('User_Profile', $match['profileId']);
            if($profile->account_id !== $user->id){
                throw new Pluf_HTTP_Error404('Profile is not blong to given user');
            }
        }else{
            $profile = self::getProfileOfUser($user);
            if ($profile === null) {
                return new User_Profile();
            }
        }
        $profile->delete();
        return $profile;
    }