Apple_Push_API\API::update_article PHP Метод

update_article() публичный Метод

Updates an existing article to a given channel.
С версии: 0.2.0
public update_article ( string $uid, $revision, string $article, array $bundles = [], $meta = [] ) : object
$uid string
$article string The JSON string representing the article
$bundles array An array of file paths for the article attachments
Результат object
    public function update_article($uid, $revision, $article, $bundles = array(), $meta = array())
    {
        $url = $this->endpoint . '/articles/' . $uid;
        // Always add the revision
        if (empty($meta['data']) || !is_array($meta['data'])) {
            $meta['data'] = array();
        }
        $meta['data']['revision'] = $revision;
        return $this->send_post_request($url, $article, $bundles, $meta);
    }