X-Git-Url: https://git.localhorst.tv/?a=blobdiff_plain;f=resources%2Fjs%2Fcomponents%2Fepisodes%2FChannel.js;h=e2d25d72bf209e59a69fc3d1ca36c79618a3f8cd;hb=4c5a82cb876e96c72c50e8bc12bd8a43a9afe847;hp=5b6c5e26e007dc67f2bc2fa4f2e3fc065b96ee19;hpb=638802eaf20d636c16d7ce337ace508708705f2c;p=alttp.git diff --git a/resources/js/components/episodes/Channel.js b/resources/js/components/episodes/Channel.js index 5b6c5e2..e2d25d7 100644 --- a/resources/js/components/episodes/Channel.js +++ b/resources/js/components/episodes/Channel.js @@ -4,10 +4,12 @@ import { Button } from 'react-bootstrap'; import Icon from '../common/Icon'; import { mayEditRestream } from '../../helpers/permissions'; -import { withUser } from '../../helpers/UserContext'; +import { useUser } from '../../hooks/user'; -const Channel = ({ channel, episode, onEditRestream, user }) => -
+const Channel = ({ channel, episode, onEditRestream }) => { + const { user } = useUser(); + + return
: null}
; +}; Channel.propTypes = { channel: PropTypes.shape({ @@ -39,8 +42,6 @@ Channel.propTypes = { episode: PropTypes.shape({ }), onEditRestream: PropTypes.func, - user: PropTypes.shape({ - }), }; -export default withUser(Channel); +export default Channel;