diff -r 1f340f3597a8 -r ea92f4fe783d client/src/components/SessionList.js --- a/client/src/components/SessionList.js Tue Oct 09 19:07:47 2018 +0200 +++ b/client/src/components/SessionList.js Mon Oct 08 18:35:47 2018 +0200 @@ -65,7 +65,7 @@ emptyListMessage = () => { - if (this.props.sessions.size === 0) { + if (this.props.sessions.length === 0) { return (

vous n'avez créé aucune session pour le moment

); @@ -75,7 +75,7 @@ deleteSession = () => { const { sessionToDelete } = this.state; - this.props.sessionsActions.deleteSession(sessionToDelete); + this.props.sessionsActions.deleteSession(sessionToDelete._id); this.setState({ modalIsOpen: false, @@ -94,17 +94,17 @@
{this.props.sessions.map((session) => -
+
- this.props.history.push('/sessions/' + session.get('_id'))}> + this.props.history.push('/sessions/' + session._id)}> {session.title || 'Session sans titre'}
- {moment(session.get('date')).format('DD/MM/YYYY')}
+ {moment(session.date).format('DD/MM/YYYY')}
{session.description}
-