public function update(array $data)
    {
        if (empty($this[static::ID_FIELD])) {
            throw new \RuntimeException(static::ID_FIELD . ' property is not defined');
        }

        return $this->put($this->getLocation(), $data)
            ->status('200')
            ->contentType('application/json')
            ->getJson();
    }
public function update(array $data)
    {
        if (empty($this[static::ID_FIELD])) {
            throw new \RuntimeException(static::ID_FIELD . ' property is not defined');
        }

        return $this->put($this->getLocation(), $data)
            ->status('200')
            ->contentType('application/json')
            ->getJson();
    }
public function update ( array $ data ) { if ( empty ( $ this [ static :: ID_FIELD ] ) ) { throw new \ RuntimeException ( static :: ID_FIELD . ' property is not defined' ) ; } return $ this -> put ( $ this -> getLocation ( ) , $ data ) -> status ( '200' ) -> contentType ( 'application/json' ) -> getJson ( ) ; }
Updates the setup options for a specific button key.

@param array $data Update data

@see https://developers.klarna.com/api/#instant-shopping-api-update-the-setup-options-for-a-specific-button-key

@throws ConnectorException When the API replies with an error response
@throws RequestException   When an error is encountered
@throws \RuntimeException  If the API replies with an unexpected response
@throws \RuntimeException  If key was not specified when creating a resource
@throws \LogicException    When Guzzle cannot populate the response

@return array Button properties
Updates the setup options for a specific button key .