mirror of
https://github.com/RaspbianFrance/raspisms.git
synced 2025-04-22 09:26:27 +02:00
Add support for hidding adapter datas
This commit is contained in:
parent
5c69237169
commit
a226139630
11 changed files with 101 additions and 0 deletions
|
@ -176,6 +176,19 @@ namespace controllers\publics;
|
|||
$entries[$key]['contacts'] = $this->internal_group->get_contacts($entry['id']);
|
||||
}
|
||||
}
|
||||
// Special case for phone as we might need to remove adapter_data for security reason
|
||||
elseif ('phone' == $entry_type)
|
||||
{
|
||||
foreach ($entries as $key => $entry)
|
||||
{
|
||||
if (!$entry['adapter']::meta_hide_data())
|
||||
{
|
||||
continue;
|
||||
}
|
||||
|
||||
unset($entries[$key]['adapter_data']);
|
||||
}
|
||||
}
|
||||
|
||||
$return = self::DEFAULT_RETURN;
|
||||
$return['response'] = $entries;
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue