protected static function setIconAttribute(array $properties)
    {
        $icon = array_get($properties, 'attributes.icon');
        if (!is_null($icon)) {
            $properties['icon'] = $icon;

            array_forget($properties, 'attributes.icon');

            return $properties;
        }

        return $properties;
    }
protected static function setIconAttribute(array $properties)
    {
        $icon = array_get($properties, 'attributes.icon');
        if (!is_null($icon)) {
            $properties['icon'] = $icon;

            array_forget($properties, 'attributes.icon');

            return $properties;
        }

        return $properties;
    }
protected static function setIconAttribute ( array $ properties ) { $ icon = array_get ( $ properties , 'attributes.icon' ) ; if ( ! is_null ( $ icon ) ) { $ properties [ 'icon' ] = $ icon ; array_forget ( $ properties , 'attributes.icon' ) ; return $ properties ; } return $ properties ; }
Set the icon property when the icon is defined in the link attributes.

@param array $properties

@return array
Set the icon property when the icon is defined in the link attributes .