title: auth0 - redirect to /login after authentication
body: <p>I am stuck in strange error. I am trying to protect my client side route. I have this code </p>
  
  <pre><code>&lt;Router history={history} component={App}&gt;
            &lt;div&gt;
  
  
              &lt;Route path="/login" render={(props) =&gt; &lt;Login auth={auth} {...props} /&gt;} /&gt;
              &lt;Route path="/apphome" render={(props) =&gt; &lt;Apphome auth={auth} {...props} /&gt;} /&gt;
              &lt;Route path="/apphome" render={(props) =&gt; (
                    !auth.isAuthenticated() ? (
                      &lt;Redirect to="/login"/&gt;
                    ) : (
                      &lt;Apphome auth={auth} {...props} /&gt;
                    )
                  )} /&gt;
              &lt;Route path="/contacts" exact component ={Contacts} /&gt;
              &lt;Route path="/mytodo" exact component ={Mytodo} /&gt;
              &lt;Route path="/favorites" exact component ={Favorites} /&gt;
              &lt;Route path="/mention" exact component ={Mention} /&gt;
              &lt;Route path="/profile" exact component ={Profile} /&gt;
              &lt;Route path="/buy" exact component ={Buy} /&gt;
              &lt;Route path="/success" exact component ={Success} /&gt;
              &lt;Route path="/cancel" exact component ={Cancel} /&gt;
  
            &lt;/div&gt;
          &lt;/Router&gt;
  </code></pre>
  
  <p>Now, i go to login page, login and it goes back to login page. But, when i dont protect this route and I have it unprotected like </p>
  
  <p></p>
  
  <p>It works perfectly and after login, i go to this Apphome component. </p>
  
  <p>I am using react.js and auth0 . What's the issue here?</p>
  
  <p>Thanks in advance</p>