From 75362a40bebff221a9031d38a0d264d8974d7c3e Mon Sep 17 00:00:00 2001 From: Brandon Boone Date: Fri, 5 May 2017 15:42:00 -0400 Subject: [PATCH 1/2] Fix for PropTypes warning in React 15.5 Fixes: "Warning: Accessing PropTypes via the main React package is deprecated. Use the prop-types package from npm instead." --- package.json | 1 + src/CallbackComponent.js | 3 ++- src/OidcProvider.js | 3 ++- 3 files changed, 5 insertions(+), 2 deletions(-) diff --git a/package.json b/package.json index e22ad10..295afe3 100644 --- a/package.json +++ b/package.json @@ -59,6 +59,7 @@ "co": ">=4.6.0", "react": ">=0.14.0", "oidc-client": ">=1.2.0" + "prop-types": ">=15.5.0", }, "optionalDependencies": { "immutable": ">=3.6.0" diff --git a/src/CallbackComponent.js b/src/CallbackComponent.js index dc6599e..8b86189 100644 --- a/src/CallbackComponent.js +++ b/src/CallbackComponent.js @@ -1,4 +1,5 @@ -import React, { PropTypes } from 'react'; +import PropTypes from 'prop-types'; +import React from 'react'; import { redirectSuccess } from './actions'; class CallbackComponent extends React.Component { diff --git a/src/OidcProvider.js b/src/OidcProvider.js index e1df147..746c50f 100644 --- a/src/OidcProvider.js +++ b/src/OidcProvider.js @@ -1,4 +1,5 @@ -import React, { PropTypes } from 'react'; +import PropTypes from 'prop-types'; +import React from 'react'; import { userExpired, userFound, silentRenewError, sessionTerminated, userExpiring, userSignedOut } from './actions'; class OidcProvider extends React.Component { From 41220b8571b1d15eb64b14fa95d156f22ee4dde0 Mon Sep 17 00:00:00 2001 From: Brandon Boone Date: Fri, 5 May 2017 15:48:17 -0400 Subject: [PATCH 2/2] Fix for package.json error. --- package.json | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/package.json b/package.json index 295afe3..86538fd 100644 --- a/package.json +++ b/package.json @@ -58,8 +58,8 @@ "peerDependencies": { "co": ">=4.6.0", "react": ">=0.14.0", - "oidc-client": ">=1.2.0" - "prop-types": ">=15.5.0", + "oidc-client": ">=1.2.0", + "prop-types": ">=15.5.0" }, "optionalDependencies": { "immutable": ">=3.6.0"