title: NuxtJs login works but unauthorized 401
body: <p>I am using <a href="https://auth.nuxtjs.org/" rel="nofollow noreferrer">NuxtJs auth module</a> to handle my authorization in the state. For the auth I wrote an express api which works.</p>
  
  <p>I have following configuration in my nuxt.config.js:</p>
  
  <pre><code>  axios: {
      baseURL: 'http://localhost:4000/api'
    },
  
    auth: {
      strategies: {
        local: {
          endpoints: {
            login: { url: '/users/login', method: 'post', propertyName: 'data.token' },
            user: { url: '/users/me', method: 'get', propertyName: 'data' },
          },
        }
      }
    },
  </code></pre>
  
  <p>And in my login component I call the login route like this:</p>
  
  <pre><code>const { data } = await this.$auth.loginWith('local', {
    data: this.login
  })
  </code></pre>
  
  <p>This call the <code>/api/users/login</code> route successfully (200) and after that calls the <code>/api/users/me</code> with an error saying</p>
  
  <blockquote>
    <p><code>xhr.js:178 GET http://localhost:4000/api/users/me 401 (Unauthorized)</code></p>
  </blockquote>
  
  <p>In postman I am calling the api route which returns the user like this*</p>
  
  <pre><code>&gt; Get - localhost:4000/api/users/me
  &gt; 
  &gt; Authorization:
  &gt; 
  &gt; Type: Bearer Token Token: xxxx
  </code></pre>
  
  <p>Which returns the users data.</p>
  
  <p>I read that nuxt auth module default the type to 'Bearer' but in my case it does not work.</p>
  
  <p>The user login work but the second route which returns the user data does not work due to authorization. The Api is not inside the nuxtjs it is a different project written in Express.</p>