From 444defc6e5709c46d935dbff8e90538156915457 Mon Sep 17 00:00:00 2001 From: Peggy Rayzis Date: Tue, 22 May 2018 13:00:54 -0400 Subject: Remove unnecessary Query component --- frontend/components/AddToCart.js | 26 +++++++++++--------------- 1 file changed, 11 insertions(+), 15 deletions(-) (limited to 'frontend/components/AddToCart.js') diff --git a/frontend/components/AddToCart.js b/frontend/components/AddToCart.js index c79e644..7cb0856 100644 --- a/frontend/components/AddToCart.js +++ b/frontend/components/AddToCart.js @@ -1,5 +1,5 @@ import { Component } from 'react'; -import { Mutation, Query } from 'react-apollo'; +import { Mutation } from 'react-apollo'; import PropTypes from 'prop-types'; import { ADD_TO_CART_MUTATION, @@ -34,21 +34,17 @@ class AddToCart extends Component { render() { const { id } = this.props; return ( - - {() => ( - - {(addToCart, { loading }) => ( - - )} - + + {(addToCart, { loading }) => ( + )} - + ); } } -- cgit v1.3