From ec1c72024b0ce53281411befe0b9a984d6dffc4a Mon Sep 17 00:00:00 2001 From: Tobias Nyholm Date: Sun, 6 Mar 2016 08:54:00 +0100 Subject: [PATCH] Prepare for 0.7 --- Upgrade.md | 32 ++++++++++++++++++++------------ composer.json | 5 ++--- 2 files changed, 22 insertions(+), 15 deletions(-) diff --git a/Upgrade.md b/Upgrade.md index 90fa467..d06912c 100644 --- a/Upgrade.md +++ b/Upgrade.md @@ -1,6 +1,13 @@ -# Upgrade from 0.6 to dev-master +# Upgrade -## Changes +This document explains how you upgrade from one version to another. + +## Upgrade from 0.7 to dev-master + + +## Upgrade from 0.6 to 0.7 + +### Changes * Introduced PHP-HTTP and PSR-7 messages * Added constructor argument for responseDataType @@ -10,10 +17,10 @@ To make sure you can upgrade you need to install a HTTP adapter. ```bash -php composer.phar require php-http/guzzle5-adapter:dev-master +php composer.phar require php-http/guzzle6-adapter ``` -## BC breaks +### BC breaks * Removed `LinkedIn::setRequest` in favor of `LinkedIn::setHttpAdapter` * Removed `LinkedIn::getAppSecret` and `LinkedIn::getAppId` @@ -22,23 +29,23 @@ php composer.phar require php-http/guzzle5-adapter:dev-master * Removed `LinkedIn::getLastHeaders` in favor of `LinkedIn::getLastResponse` * Made the public functions `LinkedIn::getResponseDataType` and `LinkedIn::getFormat` protected -# Upgrade from 0.5 to 0.6 +## Upgrade from 0.5 to 0.6 -## Changes +### Changes * When exchanging the code for an access token we are now using the post body instead of query parameters * Better error handling when exchange from code to access token fails -## BC breaks +### BC breaks There are a few minor BC breaks. We removed the functions below: * `LinkedIn::getUserId`, use `LinkedIn::getUser` instead * `AccessToken::constructFromJson`, Use the constructor instead. -# Upgrade from 0.4 to 0.5 +## Upgrade from 0.4 to 0.5 -## Changed signature of `LinkedIn::api` +### Changed signature of `LinkedIn::api` The signature of `LinkedIn::api` has changed to be more easy to work with. ```php @@ -57,7 +64,8 @@ $linkedIn->api('POST', $resource, $options) ``` See the Readme about more options to the API function. -## Must inject IlluminateSessionStorage +### Must inject IlluminateSessionStorage + We have removed the protected `LinkedIn::init` function. That means if you were using `IlluminateSessionStorage` you have to make a minor adjustment to your code. @@ -72,10 +80,10 @@ $linkedIn->setStorage(new IlluminateSessionStorage()); If you don't know about `IlluminateSessionStorage` you are probably good ignoring this. -## Default format +### Default format The default format when communicating with LinkedIn API is changed to json. -## Updated RequestInterface +### Updated RequestInterface The `RequestInterface::send` was updated with a new signature. We did also introduce `RequestInterface::getHeadersFromLastResponse`. diff --git a/composer.json b/composer.json index 7548673..cbab774 100644 --- a/composer.json +++ b/composer.json @@ -11,9 +11,8 @@ "email": "tobias@happyr.com" } ], - "minimum-stability": "beta", "require": { - "php": ">=5.4", + "php": "^5.4|^7.0", "php-http/client-implementation": "^1.0", "php-http/httplug": "^1.0", "php-http/message": "^1.0", @@ -31,7 +30,7 @@ }, "extra": { "branch-alias": { - "dev-master": "0.7.x-dev" + "dev-master": "0.8.x-dev" } } }