From 65997943686cb65caf40218c5f7a0123ccb93935 Mon Sep 17 00:00:00 2001 From: Vitaly Takmazov Date: Fri, 12 Apr 2019 00:51:04 +0300 Subject: Fix prop-types warnings --- vnext/src/components/Users.js | 15 +++++++-------- 1 file changed, 7 insertions(+), 8 deletions(-) (limited to 'vnext/src/components/Users.js') diff --git a/vnext/src/components/Users.js b/vnext/src/components/Users.js index ea3784b9..a10bba7f 100644 --- a/vnext/src/components/Users.js +++ b/vnext/src/components/Users.js @@ -1,17 +1,16 @@ import React, { useState } from 'react'; import PropTypes from 'prop-types'; +import ReactRouterPropTypes from 'react-router-prop-types'; - -import { UserType } from './Types'; import UserInfo from './UserInfo'; import Avatar from './Avatar'; -export function Friends({ user, ...rest }) { - return ; +export function Friends({ match }) { + return ; } -export function Readers({ user, ...rest }) { - return ; +export function Readers({ match }) { + return ; } function Users(props) { @@ -32,11 +31,11 @@ function Users(props) { Friends.propTypes = { - user: PropTypes.string.isRequired + match: ReactRouterPropTypes.match.isRequired }; Readers.propTypes = { - user: PropTypes.string.isRequired + match: ReactRouterPropTypes.match.isRequired }; Users.propTypes = { -- cgit v1.2.3