Pantheon\Terminus\Models\Upstream::parseAttributes PHP Method

parseAttributes() protected method

protected parseAttributes ( $data )
    protected function parseAttributes($data)
    {
        if (property_exists($data, 'attributes')) {
            $data = $data->attributes;
        }
        if (property_exists($data, 'product_id')) {
            $data->id = $data->product_id;
        }
        return $data;
    }