$res = Item::performActivity($request['id'], $this->parameters['verb'], $uid);
if ($res) {
- if (!empty($this->parameters['extension']) && ($this->parameters['extension'] == 'xml')) {
+ if ($this->parameters['extension'] ?? '' == 'xml') {
$ok = 'true';
} else {
$ok = 'ok';
$notifications[] = new ApiNotification($Notify);
}
- if (!empty($this->parameters['extension']) && ($this->parameters['extension'] == 'xml')) {
+ if ($this->parameters['extension'] ?? '' == 'xml') {
$xmlnotes = [];
foreach ($notifications as $notification) {
$xmlnotes[] = ['@attributes' => $notification->toArray()];
$profile = self::formatProfile($profile, $profileFields);
$profiles = [];
- if (!empty($this->parameters['extension']) && ($this->parameters['extension'] == 'xml')) {
+ if ($this->parameters['extension'] ?? '' == 'xml') {
$profiles['0:profile'] = $profile;
} else {
$profiles[] = $profile;
{
protected function rawContent(array $request = [])
{
- if (!empty($this->parameters['extension']) && ($this->parameters['extension'] == 'xml')) {
+ if ($this->parameters['extension'] ?? '' == 'xml') {
$ok = 'true';
} else {
$ok = 'ok';
{
protected function rawContent(array $request = [])
{
- if (!empty($this->parameters['extension']) && ($this->parameters['extension'] == 'xml')) {
+ if ($this->parameters['extension'] ?? '' == 'xml') {
$hash = [
'remaining-hits' => '150',
'@attributes' => ["type" => "integer"],